Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have attached one application in which just for practice purpose written a code to generate random rows in fact table.
But the script is giving error at '120' row FOR L=1 to $(vPCount) .
Can you please guide me to know what is wrong in the script.
Thanks in advance
Hi,
I think, character 'c' is missing in your variable, instead of vDateFactor, you written vDateFator..
let vDateFactor = pow(2,$(vWeekDay)) * (1-(Year(now())-Year($(vOrderDate)))*0.05);
// Calculate the random number of lines
let vPCount = Floor(Rand()*$(vDateFactor)) + 1;
seems like your vPCount variable hasn't survived your script reload and I can't reload your script (missing the input table).
I would suggest that you run your script in debug mode of the script editor and carefulls watch each variable being created correctly.
Hi,
I think, character 'c' is missing in your variable, instead of vDateFactor, you written vDateFator..
let vDateFactor = pow(2,$(vWeekDay)) * (1-(Year(now())-Year($(vOrderDate)))*0.05);
// Calculate the random number of lines
let vPCount = Floor(Rand()*$(vDateFactor)) + 1;
Thanks Swuehl and Settu for your Help..!!