using go in a sql batch

  • Thread starter Thread starter Patrick Jox
  • Start date Start date
P

Patrick Jox

Hello,
in SQL scripts I can use GO to force query analyzer to finalize the batch
above. Before continuing with execution of code. This is needed i.e. when i
add a new column before i can fill it.

Is there an equivalent statement that can be used when hte script is loaded
from file and executed with adonet (sqlclient) or do I have to split the
script file?

Thanks
Patrick
 
Nope, you'll need to emulate the behavior of the SQLCMD or the SSMS query
editor window. I have an example of this in the book as I used it as a lab
exercise in my TSQL classes (years ago).

--
__________________________________________________________________________
William R. Vaughn
President and Founder Beta V Corporation
Author, Mentor, Dad, Grandpa
Microsoft MVP
(425) 556-9205 (Pacific time)
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
____________________________________________________________________________________________
 
OK, Thanks.

Kind Regards
Patrick


William Vaughn said:
Nope, you'll need to emulate the behavior of the SQLCMD or the SSMS query
editor window. I have an example of this in the book as I used it as a lab
exercise in my TSQL classes (years ago).

--
__________________________________________________________________________
William R. Vaughn
President and Founder Beta V Corporation
Author, Mentor, Dad, Grandpa
Microsoft MVP
(425) 556-9205 (Pacific time)
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
____________________________________________________________________________________________
 
Back
Top