Monday, 13 May 2013

Teradata Sampling - Randomized sampling


Sampling with randomized allocation:

Sampling with randomized allocation provides ability to sample randomly across the entire system instead of each AMP returning an equal share of the sample.

In most cases, the difference in the data sampled with randomized versus non-randomized sampling will not be immediately apparent.

Following is how we request randomized allocation:

Select        employeeid,departmentno,sampleid
From        employee2
SAMPLE WITH REPLACEMENT RANDOMIZED ALLOCATION
WHEN        departmentno=100 then 4,2
WHEN        departmentno=300 then 4,4
END        ;

1 comment:

  1. Hi can you please explain this with an example

    Regards,
    Praveen

    ReplyDelete