>>Table Dodah >>A B >>1 Sack and Save >>2 Kroger >> >>Table Blah >>A C D >>1 Jackson 39185 >>2 Vicksburg 39180 >>1 Vicksburg 39182 >>2 Jackson 39184 >> >>Table Big >>A E F >>1 ATLANTA 12/15/2002 >>2 DALLAS 01/01/2003 >> >>That cursor would result in >>1 Sack and Save Jackson 39185 ATLANTA 12/15/2002 >>1 Sack and Save Vicksburg 39182 ATLANTA 12/15/2002 >>2 Kroger Vicksburg 39180 DALLAS 01/01/2003 >>2 Kroger Jackson 39184 DALLAS 01/01/2003 >>>>I need something that would result in two records for this dataset.
>>>select distinct; >>> a.Fld1,; >>> a.Fld2,; >>> b.Fld3,; >>> c.Fld4,; >>> c.Fld5; >>> From; >>> Dodah a,; >>> Blah b,; >>> Big c; >>> where; >>> a.KeyFld1 = b.KeyFld1; >>> AND a.KeyFld1 = c.KeyFld1; >>> order by; >>> a.Fld1,; >>> b.Fld3,; >>> c.Fld4; >>> into; >>> cursor C_DistinctSampleSet >>>>>>