Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
OK - how do you do this
Message
De
28/12/2000 15:28:02
 
 
À
28/12/2000 14:14:10
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Syntaxe SQL
Divers
Thread ID:
00457333
Message ID:
00457558
Vues:
25
>Ken,
>
>It is true that any temp. tables created within dynamic sql are scoped to the dynamic sql. BUT, if the temp table exists BEFORE the dynamic sql, it is within scope:
>
>CREATE TABLE #x (c int)
>
>EXECUTE ('insert into c values (1)')
>
>-Mike

Mike,

yeah - I discovered this - and is what I am using - thanks! I still think it is a PITA though :(

I also found out how to return into variables using sp_executesql, and that helps in a couple other instances. This was actually not in the SQL docs (at least I couldn't find it) I discovered it at SQL Expert site.

Thanks for your help!
Ken B. Matson
GCom2 Solutions
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform