Microsoft SQL Server
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsDatabaseMicrosoft SQL Server

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old November 18th, 2004, 11:59 AM
klegrand klegrand is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Location: Belgium
Posts: 72 klegrand User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 14 h 1 m 31 sec
Reputation Power: 4
Exclamation Send Data from SQL server to another SQL server

I want to send data (actived by a trigger when the record is updated) to another SQL server (different database) which is located on another pc. Both pc's can communicate trough TCP/IP.
Is this possible and what are the basics to establising that. Can anyone help me...

Thx in advance....
Kurt

Reply With Quote
  #2  
Old November 22nd, 2004, 06:28 PM
MrData MrData is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Nov 2004
Location: Sacramento, California, USA
Posts: 13 MrData User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 29 m 11 sec
Reputation Power: 0
Search BOL for "Linked Servers"

You need to make sure the server with the trigger has a record in its linked servers for the server receiving the data. You can use the 'Linked Servers' folder in EM (or sp_addlinkedservers in QA if you really must).

Then it's just a matter of qualifying the server in your trigger, like so:

Code:
   INSERT INTO  linked_server.database.owner.table
 SELECT column1, column2
 FROM inserted --or deleted or updated, whatever your trigger is
 WHERE condition = condition2
 


Get the picture?

Hope this helps,
Steve

Reply With Quote
  #3  
Old November 23rd, 2004, 02:01 AM
klegrand klegrand is offline
Contributing User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Oct 2004
Location: Belgium
Posts: 72 klegrand User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 14 h 1 m 31 sec
Reputation Power: 4
Thanks Steve,
This is the solution for me. I've tried this and it works.

Kurt

Reply With Quote
Reply

Viewing: ASP Free ForumsDatabaseMicrosoft SQL Server > Send Data from SQL server to another SQL server


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway