Mario,
If you want to execute a script and use the result value, probably the
solution presented by Guy is the only way to do it. Insert the result into a
temporary table and read it into a variable. But if you use a stored
procedure instead of the scrip, you can use EXEC to transfer result directly
into the variable.
EXEC @Result = YourSP(Parameters list)
Shervin
"Mario Pranjic" <ke****@fly.srk.fer.hr> wrote in message
news:tt********************************@4ax.com...
Hi!
Can anybody give me a hint how to put sa resut from EXEC into a
variable.
EXEC is called:
EXEC(@TmpQuery) and it returns a single int value (SELECT COUNT(*)
...)
Thanks!
Mario.