Home Forums SQL Server 2005 Development Global Temp Tables: Triggers Vs Stored Procedure RE: Global Temp Tables: Triggers Vs Stored Procedure

  • naveenreddy.84 (7/7/2009)


    Hi,

    Can anyone help me out with writing the code(scenario 2) using temp variables for logging errors outside the transaction scope.

    Thanks for your help!!!

    Actually, for what you're doing, you don't need either. You're creating a single-row, nvarchar(200) value. Why not just assign it to an output parameter in the second proc? Then you can have the first proc get the value from that, and you're good to go.

    Are you familiar with output parameters?

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon