hello, i have two tables menu with menuid as pk and i also have another table named as submenu with submenuid as pk and menuid as fk. if i delete one menu then atomatically related their submenu also want to delete,,, can anybody tel me how can i write the sql querry for this operation.. but i want a querry using join conditions...not a separate querries...
I don't know what your schema looks like but an easy way to test this is using SQL Server Management Studio Express (free from Microsoft) and running a select query. Management studio will let you create queries with great ease. When the results are correct change the query to delete. Another way is to create a temp database with the same schema and populate a few records and test your SQL queries. I used this approach often when I was learning