Results 1 to 4 of 4
  1. #1
    stildawn is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Oct 2013
    Posts
    185

    Update records on only ONE FIELD from excel data?

    Hi All

    I have a table which has a column called "Service". I have just been informed that the data in the "Service" field for all our records is incorrect, but there is a spreadsheet that I could do a VLOOKUP on to correct the service field for the affected records.



    My question is, is there a way to update just the one field in my access table from a excel sheet, updating the correct records in the table??

    If that makes sense?

    Cheers

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,600
    Yes, that would be an SQL action.

    Do you have an established link to the spreadsheet? If so, use the link just as any table, except can't edit the spreadsheet.

    The link can be queried, sorted, joined in query.

    Can the table and link be joined in query?

    Can use the query builder and ribbon tools to help build UPDATE query.
    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.

  3. #3
    stildawn is offline Competent Performer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Oct 2013
    Posts
    185
    Sorry I didn't understand any of that haha, I'm fairly new to Access...

    The only spreadsheet currently is a completely random one that some other department has generated... What I was planning to do was export my entire table from Access to a new Workbook.

    Then do a VLOOKUP from the Access Workbook, with the Workbook that contains the correct values for the "Service" column.

    I was then going to just delete all the amended records in the Access table, and then copy and paste in the "updated records" from the spread sheet into Access...

    But I thought there is probably a better cleaner way of doing this? Like is it possible to do a one time VLOOKUP in access itself with the random spreadsheet?

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,600
    The function in Access is called DLookup and might not be needed.

    If this is a one time event and not a gazillion records, then the copy/paste would be quick and probably simple. Assuming there are no dependent tables related to this table that are associated by autonumber primary key.

    If the spreadsheet structure is such that Access can link to it, that would be another way to go.

    Of course, have to learn a little more about Access but if you are going to use Access, then better learn it, especially the basics.

    Everything I previously described is fairly basic functionality.
    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. SQL Update query using data in Excel column
    By tylerg11 in forum SQL Server
    Replies: 2
    Last Post: 09-03-2013, 05:10 PM
  2. Importing Excel - Update table field with the worksheet name
    By maggiemago3 in forum Import/Export Data
    Replies: 1
    Last Post: 08-22-2013, 04:51 PM
  3. Replies: 3
    Last Post: 07-30-2013, 12:11 PM
  4. Replies: 5
    Last Post: 03-13-2013, 02:11 PM
  5. Replies: 14
    Last Post: 12-06-2012, 11:25 AM

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