#1
|
|||
|
|||
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! |
#2
|
|||
|
|||
Quote:
Thank you! |
#3
|
|||
|
|||
#4
|
|||
|
|||
Quote:
The real question being, how do I set the value from T-SQL variable back to a macro defined within Visual Build Pro? Thanks again! |
#5
|
|||
|
|||
Print the variable's value, parse it out of the LASTSTEP_OUTPUT macro value, and store in a macro.
http://msdn.microsoft.com/en-us/libr...SQL.90%29.aspx http://www.kinook.com/VisBuildPro/Ma...riptevents.htm |
#6
|
|||
|
|||
Thank you! You are amazing as always!
|
#7
|
|||
|
|||
name
-------------------------------------------------------------------------------------------------------------------------------- Music_log Hello, When I run the SQL to assign it to a variable, above is the output that I get from SQL. How do I parse to get only "Music_log"? Thank you! |
#8
|
|||
|
|||
See the attached sample.
|
#9
|
|||
|
|||
Do you have this .bld sample for v7.7 pro?
|
#10
|
|||
|
|||
No, but it might work if you change the version in the .bld file (in a text editor) from 8 to 7.
|
Thread Tools | |
Display Modes | Rate This Thread |
|
|