Closed SharmaAntriksh closed 1 year ago
Check the documentation here: https://docs.sqlbi.com/contoso-data-generator/databasegenerator Probably, you want to change the YearsCount parameter before setting CutDateBefore and CutDateAfter. The parameter is the tentative number of Orders, which could be slightly different in the output because of other constraints applied. Consider it as an order of magnitude, do not look for the exact number.
Q: I have noticed that the number of rows generated are never equal to the one specified in the create parameter, what's the logic here? For example this ->
$databases += [System.Tuple]::Create(8000, 'Contoso 10K', 'TrimCustomers', 'CutDateBefore=2001-05-18', 'CutDateAfter=2023-03-03', 'CustomerPercentage=0.05' )
gives 12437 total rows
I ran this twice and same number of rows are generated.
Another thing I noticed is that rows in Orders table stop at 2020-12-31 and not 2023-03-03
Then I tried this ->
$databases += [System.Tuple]::Create(1000000, 'Contoso 1M', 'TrimCustomers', 'CutDateBefore=2001-01-01', 'CutDateAfter=2022-03-03', 'CustomerPercentage=0.05')
It generates 991379 Orders and 2376561 OrderRows, so I guess the 5K or 1M applies to Orders table and the OrderRows table is ~3x of Orders? Also in this case as well the end date is limited to 2020-12-31.