Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Accumulating in a local variable
Message
From
28/05/2002 15:02:04
 
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Miscellaneous
Thread ID:
00662107
Message ID:
00662127
Views:
19
Sergey pointed out one problem - you've got the FETCH in the wrong place within the loop. What value are you seeing for @txt vs. what value do you think you should be seeing? Also, give this a try:
DECLARE @txt nvarchar(4000)

SELECT 
 @txt = @txt + texto 
FROM
 Universe.dbo.textOdi
WHERE
 certif = 'PM115451'

SELECT @txt
It should produce the same results.

-Mike
Michael Levy
MCSD, MCDBA
ma_levy@hotmail.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform