Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
USE with a variable
Message
De
22/03/2011 15:40:01
 
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Scripting
Versions des environnements
SQL Server:
SQL Server 2008
Application:
Web
Divers
Thread ID:
01504526
Message ID:
01504563
Vues:
49
>I try to always create my select statements with the database on them, I think I never use the USE statement.

Yes, this generates well when the database name is known at the time I generate the script. But, in that particular case, the user will adjust the DatabaseName variable in the script before executing it. So, I do not want to change thousands of lines so to have them to be executed as a command with the EXECUTE() comand.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform