Comments
1 comment
-
Hi,
SQL Data Generator removes the spaces from the column names. For example, if my column is named name with spaces, it would be referred to as namewithspaces in the Python script. For example, my script for the name with spaces column would be something like this -def main(config): firstName = namewithspaces if firstName == 'Lee' : return 'Lee' else: return 'Not Lee' return
There's a button underneath the script named "Insert Column Name..." - this will take care of everything for you so it makes it really easy.
I hope this helps.
Add comment
Please sign in to leave a comment.
Eg, I'm generating a sample set of "folders" for an area path - Area Level 1, Area Level 2, etc.
The example here: http://documentation.red-gate.com/displ ... on+scripts for "Years of service" shows that it is possible to get data from other columns... but that doesn't work if the column name has spaces. How can I get it to work if the column name has spaces? quotes, [], (), {}, etc. don't seem to work.
what I want is "if area level 2 is null, then area level 3 and so on should also be null"
Thanks!