Msg#: 3618631 posted 1:20 am on Apr 4, 2008 (gmt 0)
Hi, would appreciate some clues on how to do this with MySQL.
I have 2 tables in a database. Lets call them Table A (a table of usernames) and Table B (a table of transactions carried out by these usernames).
Over time some usernames have been deleted from Table A, but we did not remove their transactions from Table B. So we have Table B which has loads of transactions which no longer have corresponding users in Table A.
I want to identify and probably delete these orphan transactions! So tried "SELECT * FROM B, A WHERE B.username not like A.username"... and phpMyAdmin just hangs up with that :-(