Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> grouping problem
Hello,
I have got two tables tableA and tableB with identical structures:
-ID
-FILEID
-FIELDV01
-FIELDV02
-FIELDV03
-FIELDN01
-FIELDN02
-FIELDN03
-FIELDD01
-FIELDD02
-FIELDD03
Now user can input condition text something like:
tableA.FieldV01 = tableB.FieldV01
AND
tableA.FieldV02 = tableB.FieldV02
AND
tableA.FieldN01 >= tableB.FieldN01
and I want create records groups in third table.
Sample:
tableA
Rec_symbol FieldV01 FieldV02
A1 POI1 48 A2 POI1 48 A3 POI1 49 A4 POI1 33 A5 POI1 1
tableB
Rec_symbol FieldV01 FieldV02
B1 POI1 48 B2 POI1 48 B3 POI1 48 B4 POI1 49 B5 POI1 49 B6 POI1 33 B7 POI1 11
User condition is:
partner_file.FieldV01 = tytan_file.FieldV01
AND
partner_file.FieldV02 = tytan_file.FieldV02
Results are:
group1: A1,A2,B1,B2,B3 group2: A3,B4,B5 group3: A4,B6 group4: A5,null group5: null, B7
Can anyone help?
Thanks,
Peter
Received on Tue Oct 12 2004 - 05:46:51 CDT
![]() |
![]() |