Results 1 to 2 of 2
  1. #1
    altrotx is offline Novice
    Windows 7 64bit Access 2010 32bit
    Join Date
    Feb 2013
    Posts
    2

    Delete Query Problem


    This should be a simple delete query, I have 2 tables 1 has 1 record and 1 field field PartNum retrieved from a form field, table 2 has 6000 records with 55 fields one of which is PartNum. I need to locate the record from the field in table 1 and delete if found the record in table 2. I get the error message Specifiy the table containing the records you want to delete. I'm very new to Access and SQL

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,815
    Syntax is:

    DELETE FROM tablename WHERE fieldname=Forms!formname!fieldname;

    Show your attempted query for analysis.

    If you aren't using a form to specify criteria and just want to check all records, this would be a delete matching records. This requires 2 queries (which can be nested as one). http://msgroups.net/microsoft.public...te-query/35888
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 01-24-2012, 02:16 PM
  2. Problem With Delete Query
    By jo15765 in forum Queries
    Replies: 1
    Last Post: 12-22-2011, 11:04 AM
  3. Trying to Delete record using delete query
    By MooseOTL in forum Access
    Replies: 13
    Last Post: 10-04-2011, 02:30 AM
  4. Replies: 11
    Last Post: 03-30-2011, 01:08 PM
  5. Problem using rst.delete
    By P5C768 in forum Programming
    Replies: 3
    Last Post: 03-10-2011, 11:08 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums