Results 1 to 5 of 5
  1. #1
    tagteam is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2013
    Posts
    486

    After alter table query on sql server no longer works


    I have an access database where most of the tables are in access but I have an archive table in sql server. Usually I am just appending data to that table but if a user makes a mistake I sometimes need to pull the data back to a working table and delete it from the archive table (the sql server table)

    I used to have no problem with this but now my query says - could not delete from the specified table.

    The only thing I have done to that table in a long time is I did do an Alter table to remove two columns. I used to not get these errors. If I log in to sql server and manually run a delete command it will properly delete but not if I try to do it from the access query.

    Any ideas?

  2. #2
    CJ_London is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    11,445
    Perhaps the odbc driver is out of date. Perhaps you need to create a new link to your altered table.

  3. #3
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,954
    Instead of "moving" records, could just have one table and flag records as "inactive" with a yes/no field.

    Not using an autonumber primary key? Or no related child tables?
    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.

  4. #4
    Gicu's Avatar
    Gicu is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Jul 2015
    Location
    Kelowna, BC, Canada
    Posts
    4,121
    Refresh the link to the SQL table in your Access front-end and you should be OK. If not post back please.

    Cheers,
    Vlad Cucinschi
    MS Access Developer
    http://forestbyte.com/

  5. #5
    tagteam is offline Competent Performer
    Windows 7 64bit Access 2010 32bit
    Join Date
    Mar 2013
    Posts
    486
    I tried refreshing the link in access and recreating the ODBC connection and in the end all I had to do was delete the table from access and re add it.
    Thanks

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

Similar Threads

  1. Replies: 8
    Last Post: 04-18-2019, 05:46 PM
  2. ALTER TABLE query syntax error
    By Sck in forum Queries
    Replies: 3
    Last Post: 09-07-2018, 01:01 PM
  3. Replies: 2
    Last Post: 03-01-2017, 06:36 PM
  4. Mailing works for PRD server but not for DEV server
    By violeta_barajas in forum Access
    Replies: 0
    Last Post: 11-09-2016, 12:34 PM
  5. Data entry form no longer works
    By Jamesiv1 in forum Access
    Replies: 1
    Last Post: 05-13-2014, 09:18 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