Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

HOW DO YOU CREATE A DELETE QUERY?

Status
Not open for further replies.

jmorlock

Programmer
Joined
Apr 25, 2003
Messages
46
Location
US
HOW DO YOU CREATE A DELETE QUERY?
 
In the Design window of a new query select Delete Query from the Query Menu or the Query Type button dropdown. Now add you table to delete from and if you have specific criteria select the fields and enter the criteria. If not just drag and drop the * from the table field list. This will delete all records from the table.

Typical SQL for a deleting all records is as follows:
DELETE tblYourTable.*
FROM tblYourTable;

Typical SQL for a delete query with criteria:
DELETE tblYourTable.*
FROM tblYourTable
WHERE tblYourTable.Status = "Inactive";

I hope this helps you understand the Delete Query process.

Bob Scriver
 
Thank you very much that answers my question. I really appreciate you taking the time to help me out..
Sincerely,
Jeremy
 
My pleasure. Glad to be of assistance.

Bob Scriver
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top