Click here to Skip to main content
15,911,142 members
Home / Discussions / Database
   

Database

 
AnswerRe: stored-proc question Pin
yahao9-Oct-06 23:37
yahao9-Oct-06 23:37 
GeneralRe: stored-proc question Pin
flippydeflippydebop10-Oct-06 0:15
flippydeflippydebop10-Oct-06 0:15 
GeneralRe: stored-proc question Pin
Frank Kerrigan11-Oct-06 2:48
Frank Kerrigan11-Oct-06 2:48 
GeneralAccessing SQL via VPN firewall Pin
hairy_hats9-Oct-06 22:47
hairy_hats9-Oct-06 22:47 
GeneralRe: Accessing SQL via VPN firewall Pin
Colin Angus Mackay10-Oct-06 0:53
Colin Angus Mackay10-Oct-06 0:53 
GeneralRe: Accessing SQL via VPN firewall Pin
Frank Kerrigan11-Oct-06 3:08
Frank Kerrigan11-Oct-06 3:08 
QuestionMS Linked Servers and Triggers [modified] Pin
flippydeflippydebop9-Oct-06 3:47
flippydeflippydebop9-Oct-06 3:47 
AnswerMS Linked Servers and Triggers Solution/Hack! Pin
flippydeflippydebop10-Oct-06 0:15
flippydeflippydebop10-Oct-06 0:15 
Okay guys this one definatly tripped me up but ive managed to find a way to sort it. Firstly this table syncronisation is only a tempory job which i want for a couple of weeks so i didnt want to go through the whole replication bag. That is just to heavy-duty for what i need, and something that want be around in a month or so.

So, after reading a post over at MSDN forums i found that the reason why the call to the stored-proc works inside Query Analyzer. Query Analyzer only requires the oledb to support ITransactionLocal. - But triggers require ITransactionJoin.

I looked into distributed transactions but but couldnt come up with any work-arounds. It looks like there is a problem with our security settings and distributed transactions across the two servers.

In the end i stumbled upon this hack and added a "COMMIT TRANSACTION" as the first line of the trigger and this worked. - I guess this is commiting the distributed transaction first. Then i added the call to my stored-proc which now works.

the trigger now looks like this:

<br />
IF EXISTS (SELECT name FROM sysobjects WHERE name = 'trig_testCopyDataAcrossDb' AND type = 'TR')<br />
DROP TRIGGER trig_testCopyDataAcrossDb<br />
GO<br />
CREATE trigger trig_testCopyDataAcrossDb on testbed FOR update, insert AS<br />
<br />
BEGIN<br />
   COMMIT TRANSACTION<br />
   EXEC servant.testbed..sp_AddRecord<br />
END

QuestionSQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
steve_rm9-Oct-06 1:06
steve_rm9-Oct-06 1:06 
AnswerRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
yahao9-Oct-06 5:30
yahao9-Oct-06 5:30 
QuestionRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
steve_rm9-Oct-06 7:57
steve_rm9-Oct-06 7:57 
AnswerRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
Private_Void9-Oct-06 8:46
Private_Void9-Oct-06 8:46 
QuestionRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
steve_rm9-Oct-06 22:17
steve_rm9-Oct-06 22:17 
AnswerRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
yahao9-Oct-06 23:44
yahao9-Oct-06 23:44 
QuestionRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
steve_rm10-Oct-06 0:09
steve_rm10-Oct-06 0:09 
AnswerRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
yahao10-Oct-06 0:30
yahao10-Oct-06 0:30 
AnswerRe: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified Pin
Private_Void10-Oct-06 3:04
Private_Void10-Oct-06 3:04 
Questionadding row to database Pin
ranro20068-Oct-06 19:12
ranro20068-Oct-06 19:12 
AnswerRe: adding row to database Pin
Dave Sexton9-Oct-06 3:02
Dave Sexton9-Oct-06 3:02 
GeneralRe: adding row to database Pin
Frank Kerrigan11-Oct-06 5:33
Frank Kerrigan11-Oct-06 5:33 
GeneralRe: adding row to database Pin
Dave Sexton11-Oct-06 20:40
Dave Sexton11-Oct-06 20:40 
QuestionDB Design Pin
monrobot138-Oct-06 14:44
monrobot138-Oct-06 14:44 
AnswerRe: DB Design Pin
i.j.russell9-Oct-06 0:09
i.j.russell9-Oct-06 0:09 
AnswerRe: DB Design Pin
Colin Angus Mackay9-Oct-06 3:30
Colin Angus Mackay9-Oct-06 3:30 
GeneralRe: DB Design Pin
monrobot139-Oct-06 8:12
monrobot139-Oct-06 8:12 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.