I figured out what the problem is.
First the SQL statement I used was just fine. Partial keys with = will find all the records with THAT part of the key.
The problem was when using PgSql connections IF you have one instance of the connection and try to read one table, and then another table with the SAME connection it will close the first instance of it when it tries to read the second table (and third if you have to go to another table.)
What you do is have more than one instance and yep, the first one stays open, and the second one reads the other table and,in my case, deletes the records in the second table before going back to read a second record in the first table.
What I'm doing is basically a cascading delete. Table A connects to bridge table B and bridge B connects to table C.
When deleting one record in Table A you have to find all the bridge records (B) and all the records in the third table (C) that connect back by the bridge. As you pickup a record in C you delete it. Then back to B and delete that record and then down one more in the table till you run out of related records. Then in the end delete the A record.
Our DBA is going to fix that one day so the SQL creation has a cascading delete but until they do, I have a way to cascade delete the related records in three tables for the online form I am working on.
Thanks for your help!