Results 1 to 2 of 2

Thread: delete query

  1. #1
    Join Date
    Mar 2006
    Posts
    42

    Unanswered: delete query

    I have the following query which i like to convert into a delete query and use the command
    Dim StrDelete As String
    DoCmd.RunSQL StrDelete
    Can you help me ?

    My query is the following :

    SELECT [order details].OrderID, products.grade, [order details].ProductID, [order details].cartons, [order details].Quantity, [order details].liters, products.size, products.branch0, products.items0, orders.customerid,
    Customers.Customerid FROM (([order details] INNER JOIN products ON [order details].ProductID = products.Productid) INNER JOIN orders ON [order details].OrderID = orders.orderid) INNER JOIN Customers ON orders.customerid = Customers.Customerid
    WHERE ((([order details].OrderID)=(SELECT Max([orderid]) FROM orders)))ORDER BY products.grade;

  2. #2
    Join Date
    Aug 2002
    Location
    Northampton, England
    Posts
    266
    You can change a select query to a delete query by simply going in to the query grid and changing the view to SQL view, then Query and change the query type to Delete Query. What exactly are you trying to delete?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •