View Single Post
  #1  
Old 10-29-2012, 02:39 PM
raghuk raghuk is online now
Registered User
 
Join Date: 02-10-2012
Posts: 11
Set temp macro from result of Run SQL action

Hello,

I have a need to set a local variable macro based on if the database exists or not.

I have the following query in "Run SQL" action.

if db_id('%CurrentDatabaseName%') is null
BEGIN
-- ???? STEP TO set local variable which effectively says 'NO DB'
END

How can I achieve this?

Thanks!
Reply With Quote