How to even describe?
I've got a one-to-many relationship with a table. Table A has a row that relates to many in Table B.
I want to delete a row from Table B and have it check to see if Table A still has any related rows in Table B. If none, delete the related row in Table A.
Is there any way to do this without needing to making a second query to check that there are no more related rows in Table B?