I'm using one table and two fields to extract data. What I'm try to achieve is to use the results from on field NLA and re-run the query from the same table kind of looping through. Can I use a sub query to achieve this or do I need to loop through the results? How would I write the query. Below is a sample what I'm trying to do. Your help would be much appreciated.
SELECT "PN_NEXT_LOWER_ASSEMBLY"."NHA_PN" AS "NHA_PN",
"PN_NEXT_LOWER_ASSEMBLY"."NLA_PN" AS "NLA_PN"
WHERE ( "PN_NEXT_LOWER_ASSEMBLY"."NHA_PN" = '71-20002-1'
Now I want to use each result from the NLA field and replace the above query with
WHERE ( "PN_NEXT_LOWER_ASSEMBLY"."NHA_PN" = '2293B020000') AND IF THE RESULT P/N HAS NO NLA SKIP TO NEXT RESULT P/N to achieve