Results 1 to 5 of 5
  1. #1
    zbaker is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2014
    Posts
    18

    SQL update Query

    UPDATE tblMASTERDeviceTable


    SET tblMASTERDeviceTable.Manufactuer = datadump.Manufactuer
    FROM datadump, tblMASTERDeviceTable
    WHERE tblMASTERDeviceTable.ItemNumber = datadump.Item Number

    I keep getting syntax error missing operator. Does anyone have an idea why?

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,849
    Try
    Code:
    UPDATE  tblMASTERDeviceTable  Inner Join datadump
    ON tblMASTERDeviceTable.ItemNumber = datadump.Item Number
    SET tblMASTERDeviceTable.Manufactuer = datadump.Manufactuer

  3. #3
    zbaker is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2014
    Posts
    18
    That fixed the syntax error but it does not do what i want it to do.
    I am trying to update the manufacturer field in one table to match the other table based on the item number field. When i run the update query it asks for a manufacturer name.
    Thoughts?

  4. #4
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    If your field name is Item Number (with a space), you need to enclose it in square brackets : [Item Number]

  5. #5
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,849
    We don't know the fields in your tables. I just rearranged to code in your query to remove the error.
    However, if you selected the wrong fields in your query, you need to change the fields as required and use the format I posted in post #2.
    Last edited by orange; 02-06-2015 at 04:27 PM.

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

Similar Threads

  1. Replies: 14
    Last Post: 08-12-2014, 06:33 AM
  2. Replies: 3
    Last Post: 05-27-2014, 09:31 AM
  3. Replies: 7
    Last Post: 08-26-2013, 06:05 AM
  4. Replies: 2
    Last Post: 08-30-2012, 07:59 AM
  5. Replies: 4
    Last Post: 11-10-2011, 03:41 PM

Tags for this Thread

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