Results 1 to 4 of 4
  1. #1
    CodeLiftSleep is offline Advanced Beginner
    Windows 10 Access 2013 32bit
    Join Date
    May 2017
    Posts
    48

    Angry Access form not saving data to backend DB in some cases

    I am at my wit's end on this one,



    I have a form where people can make changes to their inputs and it calculates a "scorecard" for them and then saves it to the backend DB. When they go back to the initial form it refreshes the page and shows the updated info. This was working fine for quite some time but all of a sudden, it no longer is updating properly.

    The information is there and correct(I'm checking the field value properties immediately prior to updating via putting a breakpoint on the Update call), but when it calls RS.Update, the information is not being updated at all in the DB. I check the backend DB and the information is still the same as it was prior to the update.

    Specifically, it's only the scores that aren't updating. The data is updating fine. So for instance, I have ClientVisits and change it from 3 to 4, that updates fine. But when it goes to update JunScore(which takes in all the data for the month and spits out a score), that doesn't save at all. So it seems like it is selectively updating...

    I thought it might have something to do with the datatype, but no, all the score columns are number and the values being passed in are 2 digits numbers.

    Anyone have an idea of what could be happening? No errors are being generated, it just isn't updating.

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,550
    strange. once you update ,it stays. check:
    all table links are pointing correctly,
    then run an update links anyway.
    if you are entering data via parent/sub tables, make SURE the sub table is Linked on the form via the parent key. IF not you may get orphans.

  3. #3
    Micron is offline Very Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    13,423
    I'm checking the field value properties immediately prior to updating via putting a breakpoint on the Update call), but when it calls RS.Update, the information is not being updated at all in the DB. I check the backend DB and the information is still the same as it was prior to the update.
    This probably isn't it, but if you are looking at table data, then running an operation on that table, viewing the table again does not refresh the view. To ensure this isn't the problem, click Refresh All on ribbon when the table is the active window. If that's not it, something must have changed which has caused the query to fail. Are these two updates separate queries?
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  4. #4
    CodeLiftSleep is offline Advanced Beginner
    Windows 10 Access 2013 32bit
    Join Date
    May 2017
    Posts
    48
    Quote Originally Posted by Micron View Post
    This probably isn't it, but if you are looking at table data, then running an operation on that table, viewing the table again does not refresh the view. To ensure this isn't the problem, click Refresh All on ribbon when the table is the active window. If that's not it, something must have changed which has caused the query to fail. Are these two updates separate queries?
    It was actually a piece of code that I meant to remove and forgot to causing the issue....before I realized you can control allowing NULL's in Access by using Required, I wrote code to check the fields and made them "" if they were NULL before saving...

    This was throwing a silent error because some of the fields that were NULL apparently were number fields, so some of them weren't updating properly...I removed the code and it now works as expected.

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

Similar Threads

  1. Replies: 1
    Last Post: 07-13-2017, 05:43 PM
  2. Replies: 4
    Last Post: 04-25-2015, 09:27 AM
  3. Cannot Access Backend Data
    By JimmieC in forum Access
    Replies: 9
    Last Post: 02-12-2015, 01:17 AM
  4. Replies: 1
    Last Post: 04-14-2014, 07:12 PM
  5. Access 2010 Data not saving
    By Stenya1177 in forum Access
    Replies: 1
    Last Post: 07-07-2011, 09:41 AM

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