Problem with simpe expression generator
patrykk
Posts: 2
I have an issue with SQL Data Generator. When I try to isnert function random.randint(int1,int2) in simple expression field i get error" NameError: name 'random' is not defined."
How i can solve this problem ?
I would be grateful for answer.
How i can solve this problem ?
I would be grateful for answer.
Comments
This version works - https://www.python.org/download/releases/2.6.6/
Once you have installed it, open SQL Data Generator and from the Tools menu, choose Application Options and then you'll see a "Python libraries:" text box on the General tab. Add the path to the lib folder of your new Python install to this. For example, my text box now has this as the contents -
Save the changes and this should get things working for you.
Let me know if you need any more assistance.
Redgate Software
Is there an ETA on the fix for the Python 2.7 bug?
Unfortunately not. Although I have found a workaround. You can import the random functionality from the .net assembly's CLR itself. Here's an example -
I hope this helps.
Redgate Software