Some help desparately needed with database update, Please 
Author Message
 Some help desparately needed with database update, Please

Hi
I am in a desparate situation and will appreciate any help which can save me
from it.
I have developed a simple application which need to be tested by few speech
impaired patients on Friday and unfortunately application does not work
because of fatal error which I have not been able to fix it.

I have used FoxPro database files in this application and actually the
application manipulates these data files. I open these database files
at the start of application and create Dynasets from these databases.

I use VB's ADDNEW, EDIT, and UPDATE methods to populate these files
(Dynasets) with the data received from user.
When the application uses UPDATE method for seven times at the eight
UPDATE visualbasic comes back with the error message "Too many
transactions nested" and crashes.
I haven't used any BEGINTRANS ..... COMMITTRANS statements and I
don't know how VB starts transactions implicitly by itself.
When I try to enclose my UPDATE, EDIT or ADDNEW methods with
BEGINTRANS......COMMITTRANS it happens regardless.
I have trided for whole day to find an answer to this problem but no
luck in searching the VB KB, manuals or help files.
Could anyone please by any chance direct me in the right direction if
they have experience with database manipulation with VB.
I'm really desparate and appreciate any help.
Regards
Reza Oskouie
--
+----------------------------------------------------------------------------
------------------------------+
|  Reza Oskouie   Tel: (+44)  0114-22 22412       E-mail:

|  Address: Dept. of Human Communication Sciences, The University  of
Sheffield
|                 18 Claremont Crescent   Sheffield    S10 2TA
+----------------------------------------------------------------------------
-------------------------------+



Fri, 31 Mar 2000 03:00:00 GMT  
 Some help desparately needed with database update, Please

If you haven't done it yet, you should step through your code --
particularly the sections where you're updating the database -- and find out
what sequence your AddNew/Edit and Update statements are coming in.

It sounds like your code is executing like this:

rs.Edit
....
rs.AddNew
....
rs.Edit
.....
rs.Update

What you want is probably more along the lines of:

rs.Edit
....
rs.Update
rs.AddNew
....
rs.Update
rs.Edit
.....
rs.Update

Each time you begin an Edit or AddNew operation, you're beginning an
implicit transaction. Update commits the transaction. Make sure your updates
and commits are paired, not nested.

Quote:

>Hi
>I am in a desparate situation and will appreciate any help which can save
me
>from it.
>I have developed a simple application which need to be tested by few speech
>impaired patients on Friday and unfortunately application does not work
>because of fatal error which I have not been able to fix it.
<snip>
>I use VB's ADDNEW, EDIT, and UPDATE methods to populate these files
>(Dynasets) with the data received from user.
>When the application uses UPDATE method for seven times at the eight
>UPDATE visualbasic comes back with the error message "Too many
>transactions nested" and crashes.
>I haven't used any BEGINTRANS ..... COMMITTRANS statements and I
>don't know how VB starts transactions implicitly by itself.
<snip>
>Regards
>Reza Oskouie
>--
>+--------------------------------------------------------------------------
--
>------------------------------+
>|  Reza Oskouie   Tel: (+44)  0114-22 22412       E-mail:

>|  Address: Dept. of Human Communication Sciences, The University  of
>Sheffield
>|                 18 Claremont Crescent   Sheffield    S10 2TA
>+--------------------------------------------------------------------------
--
>-------------------------------+



Fri, 31 Mar 2000 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. VB6 beginner needs help (desparately)

2. Desparately need Help! (Textbox on Picturebox)

3. Help needed desparately - stand-alone compiler

4. -= DESPARATELY need Help =-

5. ActiveX/VB gurus - desparately need help

6. Desparately need help...

7. PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP, PLEASE HELP,

8. newbie help please - update a record in a database

9. Please help with updating database field

10. Updating Database Records - Please Help!

11. newbie help please - update a record in a database

12. Database Update tool, PLEASE HELP

 

 
Powered by phpBB® Forum Software