Newbie! Deleting Records across Tables

Newbie! Deleting Records across Tables

Post by Andrew D. Weis » Sun, 03 Jun 2001 00:17:20



Encoutering somthing new here. I Have a recipe database. I want to delete a
recipe from the Recipes table but also the coresponding MealCategory,
FoodCategory and Ingrediants, that relate to the recipe, from their tables
as well.

But, If the Ingrediant, Meal Category or FoodCategory is being used by
another Recipe, I don't want to delete it.

I'm using ASP Pages with MS Access 2000
Thanks for your help
-andy

 
 
 

Newbie! Deleting Records across Tables

Post by BP Margoli » Sun, 03 Jun 2001 07:53:53


Andrew,

Quote:> I'm using ASP Pages with MS Access 2000

Probably best posted to an Access newsgroup then, rather than a SQL Server
one. Nevertheless, if you want assistance in formulating the DELETE command
then might I suggest that you post (simplified) table schemas (CREATE
TABLEs), sample data (INSERTs) and the results you want using the sample
data.

By posting this information, we are able to ensure that a query is
meaningful to your database.

-------------------------------------------
BP Margolin
Please reply only to the newsgroups.
When posting, inclusion of SQL (CREATE TABLE ..., INSERT ..., etc.) which
can be cut and pasted into Query Analyzer is appreciated.



Quote:> Encoutering somthing new here. I Have a recipe database. I want to delete
a
> recipe from the Recipes table but also the coresponding MealCategory,
> FoodCategory and Ingrediants, that relate to the recipe, from their tables
> as well.

> But, If the Ingrediant, Meal Category or FoodCategory is being used by
> another Recipe, I don't want to delete it.

> I'm using ASP Pages with MS Access 2000
> Thanks for your help
> -andy


 
 
 

1. Newbie! Deleting Records across Tables

Encoutering somthing new here. I Have a recipe database. I want to delete a
recipe from the Recipes table but also the coresponding MealCategory,
FoodCategory and Ingrediants, that relate to the recipe, from their tables
as well.

But, If the Ingrediant, Meal Category or FoodCategory is being used by
another Recipe, I don't want to delete it.

I'm using ASP Pages with MS Access 2000
Thanks for your help
-andy

2. cursor Problem

3. Newbie question on delete the record in MS Access2000 table

4. Shifting data to new server O7.3

5. Cannot add record to Visual Foxpro table after deleting all records in table

6. problem with scheduling dts package with email

7. ado .delete deletes joined table records?

8. Testing a datatype in a stored procedure

9. Deleted records when text file is linked as table (#deleted)

10. Insert across 2 tables - newbie help!

11. Newbie: Need Help in sharing common data tables across schemas

12. Insert across 2 tables - newbie help!

13. Insert across 2 tables - please help newbie!