Home > database >  DB2 database query problem
DB2 database query problem

Time:10-02

A list of existing test contains two fields idA and idB, how to use a SQL implementation will be two fields all related id as a set of output,
Example:
IdA idB
A, B
B C
B D
D G
F H
F J
Expected results:
No id
1 A
1 B
1 C
1 D
1 G
2 F
2 H
2 J

CodePudding user response:

CodePudding user response:

SQL statements to write this bad writing, or by code implementation

CodePudding user response:

Sent to Oracle section, someone should answer

CodePudding user response:

reference yuxiangaaaaa reply: 3/f
to Oracle section, someone should answer


Ok, thank you!

CodePudding user response:

  •  Tags:  
  • DB2
  • Related