Ensure correct sql server instance db in script before executing? -


How can I specify in my .sql script that it only executes against my localhost SQL Server DB frequency And not on any other open connection to my integration or test environment?

dbsetupscript.sql

  Use myDB - Wifet Safe Goud I can keep here to make sure that this script can only be executed by VIA DELETING TABLES Before starting my local environment, etc.? Delete Mother Removal - Delete other tables and enter duplicate production data    

Try

code should be something like

  if (@@ serverName = 'localhost') Delete DEBT MadreTel - Delete other tables and enter simulated production data END ELSE print 'incorrect example'    

Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -