Controlling the distribution of generated data
ranjeet
Posts: 4
HI
Is there any means by which we can control the distribution of generated test data.
i.e I have a 'VISIT' table with a column name 'VISIT TYPE' [with any one of three types of input data 'Inpatient','Outpatient' or 'Emergency'], so i would like to generate the data in such a manner that 60% of the generated data should be 'Inpatient', 20% should be 'Outpatient' and 20% should be 'Emergency'.[If we are generating 100 rows for visit table then 'VisitType' column should contain 60-Inpatient , 20-Outpatient,20-Emergency data rows]
Regards,
Ranjeet
Is there any means by which we can control the distribution of generated test data.
i.e I have a 'VISIT' table with a column name 'VISIT TYPE' [with any one of three types of input data 'Inpatient','Outpatient' or 'Emergency'], so i would like to generate the data in such a manner that 60% of the generated data should be 'Inpatient', 20% should be 'Outpatient' and 20% should be 'Emergency'.[If we are generating 100 rows for visit table then 'VisitType' column should contain 60-Inpatient , 20-Outpatient,20-Emergency data rows]
Regards,
Ranjeet
Comments
You could add the values as:
Inpatient 6
Outpatient 2
Emergency 2
Redgate Software
Thanks for the reply.I tried to generate the data with the "Weighted List" as you mentioned.But it is not generating exact number of rows
for eg: When I tried to generate 100 rows .it will generate 55 -Inpatient,25-Outpatient and 15-Emergency.
If i generate only 10 rows then it will generate 7-Inpatient , 3-Outpatient and it will not generate any Emergency values.
Regards,
Ranjeet.
Redgate Software
I tried with 60%,20%,20% and it is generating 'Inpatient-55','Outpatient-25'and 'Emergency-20' and my seed value is 3068.If you need any info please let me know.
Regards,
Ranjeet
I've raised a bug (SDG-945) for this to get looked at; although I'm not sure when this will be unfortunately.
Redgate Software