views:

160

answers:

1

I'm trying to run some dynamic SQL in an installscript project. In the UI portion of the script I have the following code:

TextSubSetValue("<INSERTSITES>", message, TRUE);
message = "";
MessageBox(message, INFORMATION);
TextSubGetValue("<INSERTSITES>", message, FALSE, TRUE);
MessageBox(message, INFORMATION);

The message boxes are just for debug and output the nothing and then the insert statement as you would expect. In my sql scripts section i have a script that is just:

$$ISITES$$

Then my Text Replacement tab looks like this: Text Replacement

But for some reason the replacement just ends up with a blank string. Am I missing something? Where/When does the replacement even happen?

+1  A: 

Replacements cannot be the only thing in the file or the file isn't run. I added a select statement at the end of the file like this:

$$ISITES$$
SELECT * FROM [Site]

Which makes the file run with the replacement.

Mykroft

related questions