473,395 Members | 1,526 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

ASP Update on Access Datebase

rp
Not sure if this is an Access Issue or ASP but here goes

I have an asp script which does an which opens up a recordset against an
access table

I then do a .AddNew.
<insert the date into the record set>
then .Update

I do the update this way as I need to get the ID (AutoNumber) from what I've
updated using

CallID = rcSet("id")

This all works fine and the record gets added to the table. My problem is a
little further in the code I do a select on this table which should pick up
this inserted record but it doesn't find it. I know my SQL is ok as I can
manually run the sql against access and it picks up the row.

It seems like there a some kind of delay between actually doing a recordset
update and it being available to select?

Any help would be appreciated.

Thanks,

Rick
Jul 19 '05 #1
2 1597
As I recall, to solve this problem, I used
Dim rec
set rec = server.createObject("ADODB.Recordset")
rec.open conn, sql, adopenkeyset, adlockoptimistic //I think you are opening
the recordset using adopendynamic.

If this doesn't work, you can always close the recordset and then get it
using a Select query.

--
Fadi El-Eter, itoctopus - http://www.itoctopus.com
"rp" <rpurse#hotmaildot.com> wrote in message
news:uI**************@TK2MSFTNGP11.phx.gbl...
Not sure if this is an Access Issue or ASP but here goes

I have an asp script which does an which opens up a recordset against an
access table

I then do a .AddNew.
<insert the date into the record set>
then .Update

I do the update this way as I need to get the ID (AutoNumber) from what I've updated using

CallID = rcSet("id")

This all works fine and the record gets added to the table. My problem is a little further in the code I do a select on this table which should pick up this inserted record but it doesn't find it. I know my SQL is ok as I can
manually run the sql against access and it picks up the row.

It seems like there a some kind of delay between actually doing a recordset update and it being available to select?

Any help would be appreciated.

Thanks,

Rick

Jul 19 '05 #2
rp wrote:
Not sure if this is an Access Issue or ASP but here goes

I have an asp script which does an which opens up a recordset against
an access table

I then do a .AddNew.
<insert the date into the record set>
then .Update

I do the update this way as I need to get the ID (AutoNumber) from
what I've updated using

CallID = rcSet("id")

This all works fine and the record gets added to the table. My
problem is a little further in the code I do a select on this table
which should pick up this inserted record but it doesn't find it. I
know my SQL is ok as I can manually run the sql against access and it
picks up the row.

It seems like there a some kind of delay between actually doing a
recordset update and it being available to select?


Yes. Jet caches transactions to improve performance. See this article for a
way to force it to refresh the cache:
http://support.microsoft.com/?kbid=240317

Bob Barrows
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
Jul 19 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

12
by: jimserac | last post by:
I had previously posted this in an Access forum with negative results so will try here. Although this question specifies an Access database, I also wish to accomplish this with a large MS SQL...
5
by: Andy P via AccessMonster.com | last post by:
I am responsible for maintaining our departmental intranet pages at work. I would like to put a link from our website to a MS Access database which is held on our Network drive. The problem I...
5
by: PAUL | last post by:
Hello, I have 2 tables with a relationship set up in the dataset with vb ..net. I add a new record to the parent table then edit an existing child record to have the new parent ID. However when I...
3
by: Roy | last post by:
Hi Access gurus, I have a A2K application.The data in the database is updated daily by a excel download.I have a master n related tables keyed in by a OrderID.I have a problem in updating data.If...
1
by: mbsevans | last post by:
New Access user here. I have a simple datebase containing employee information. I have 3 differents dates which reflect the DUE date for a qualification that each employee needs in order to continue...
14
by: sarahraj | last post by:
i am new to this ms access 2000. i have created a form in that i have created calcualte control. the calculated control value is not storing in the datebase. Anyone pls help me. Thanks
2
by: RRsonawane11 | last post by:
hi, i am designing a datebase i.e. User Master where i wan that user id is auto generated.i.e. whenever new user is created that user must get unique user id n which must be auto generated... for...
1
by: dougmeece | last post by:
Good Morning Everyone, I had a idea that I woulld like to pose to the forum. I have no idea if this is possbile but from what I could find searching it does not appear to be. I created a...
3
by: Michel Esber | last post by:
Hi all, DB2 V8 LUW FP 15 There is a table T (ID varchar (24), ABC timestamp). ID is PK. Our application needs to frequently update T with a new value for ABC. update T set ABC=? where ID...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.