Re: SQL updates to Access db table taking their time...
From: Val Mazur (group51a_at_hotmail.com)
Date: 03/11/04
- Next message: Ed Jolly: "Can't get DBGRid to refresh after changing parameter"
- Previous message: Val Mazur: "Re: mouse wheel"
- In reply to: Brad Pears: "SQL updates to Access db table taking their time..."
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 10 Mar 2004 22:28:27 -0500
Hi Brad,
Are you using Access database? If yes, then Jet caches changes to the
database in local memory for 5 seconds and you will not see those changes
right away. See next KB about how to avoid this issue
http://support.microsoft.com/default.aspx?scid=kb;en-us;200300
-- Val Mazur Microsoft MVP "Brad Pears" <bradp@truenorthloghomes.com> wrote in message news:upm92ifBEHA.2632@TK2MSFTNGP12.phx.gbl... >I have something happening in my VB 6.0 app that is driving me crazy.... >(DB > is Access 2000 ) > > I have a listview on the screen containing records from a master table. > The > user is able to double click a listview item, which then gives them a > screen > where they can modify data in the table. > > To update data, I use an SQL clause and simply execute it i.e. > > strSQl = "update TABLE set field = " & fldValue > oconn.execute strSQL > > (oconn is an ADODB connection) > > When the update is complete, I refresh the items in the listview. i.e. > clear all listview items and reload them from the same table I just > updated... ( I know I can simply redisplay the actual listview item I was > on > but this isn't what I am doing right now) > > However, sometimes, upon return to the listview from the update screen, > the > newly updated data does not show up - instead, the old data is still > there. > Then if I exit the screen and come back in, voila, there are the changes! > It appears the the changes are not being made to the table immediately > when > updating. I have this problem with just about every listview I have where > the user can update data. > > It does not happen all the time, just often enough for me to get calls > from > the users occasionally asking "How come my changes aren't made?" Then I > tell > them they have been saved, just exit that particular screen, come back in > and you'll see them... > > I have tried using a wait loop i.e. for i = 1 to 100000, next i etc.. to > let > the db updates complete first before redisplaying the listview but that > doesn't seem to work either. > > Maybe the problem is more with the listview caching data behind the > scenes??? I do not know how this control works internally... > > Any help would be much appreciated... > > Brad > >
- Next message: Ed Jolly: "Can't get DBGRid to refresh after changing parameter"
- Previous message: Val Mazur: "Re: mouse wheel"
- In reply to: Brad Pears: "SQL updates to Access db table taking their time..."
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|