# Miscellaneous > SQL Scripts >  Deleting rows from one table where foriegn key doesn't exist in another.

## Lavender

Hi,

I would like to know how to delete  rows from one table that are not associated with any rows in another table. Please help me with this. Thanks.

~Lavender

----------


## rmiao

Do you need to check other tables? If no, just delete it.

----------


## Lavender

Yes, I have to check for atleast one more table.

----------


## rmiao

Which rdbms do you use? In MS sql, you can use exists to test for the existence of rows.

----------


## Lavender

I use 10g. I was able to delete the rows.

thanks.

----------

