Help: SQL Query Question

  • Thread starter Thread starter andi
  • Start date Start date
A

andi

Hi All,
I have a table consists of two fields.

FielChild FieldParent
B1 B2
B2 B3
B3 Null

means that B3 is the parent of B2 & B1
and B2 is the parent of B1, and B1 has no child.

what I need is an sql query that can display the children of B1, B2, and B3.
e.g the result for B3 should look like:

Parent Child
B3 B3
B3 B2
B3 B1
B2 B2
B2 B1
B1 B1

TIA,
andi
 
Hi All,
I have a table consists of two fields.

FielChild FieldParent
B1 B2
B2 B3
B3 Null

means that B3 is the parent of B2 & B1
and B2 is the parent of B1, and B1 has no child.

what I need is an sql query that can display the children of B1, B2, and B3.
e.g the result for B3 should look like:

Parent Child
B3 B3
B3 B2
B3 B1
B2 B2
B2 B1
B1 B1

TIA,
andi
 
Back
Top