Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Update Command not Updating at once
Message
 
To
01/11/2006 01:34:19
General information
Forum:
Visual FoxPro
Category:
Client/server
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows XP
Database:
MS SQL Server
Miscellaneous
Thread ID:
01165839
Message ID:
01166074
Views:
18
>>You always must check the result of SQLEXEC(), try this and tell us the result:
>
>>    text to lcSql noshow
>>         update acc_mf
>>            set ob_dr = ob_dr + ?lnObDr,
>>                ob_cr = ob_cr + ?lnObCr
>>          where ac_level < '5'
>>            and ac_no = ?lcAcNo
>>      endtext
>>      IF SQLExec(hConn, lcSql) < 0
>>         AERROR(laError)
>>         MessageBox([Can not update table ] +laError[1,2])
>>      ENDIF
>......
>
>
>SQLExec() is running without any problem. SQLExec() Returns 1 when I run it. I think COMMIT has to do with this, But on backend setting is Autocommit, which is Default behaviour of SQL Server.
>As I said it DOES update the records but only 1 level up per execution.
>When I run it 2nd time, again 1 level up and so on.

Zahid,
It is hard to me to say WHY it isn't updated at once becuase I don't know what rcords you have in MGC table, how it is indexed and what is your current record.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform