Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to know if I changed the field
Message
 
 
To
13/02/2004 10:18:51
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00876888
Message ID:
00877110
Views:
21
It's a bug that was fixed in VFP8. You cannot get correct @@ROWCOUNT value with separate select. You may create a stored procedure witrh those 2 commnads and call it from VFP. Even better, you can return @ROWCOUNT as output parameter in that case. See Re: Can stored procedures return values? Message #876903.

>How come this doesn't work?
>
>= SQLSETPROP(ln_sql,'BatchMode', .T.)
>? SQLEXEC(ln_Sql, "UPDATE SCHEDULE SET SCHEDSTAT = 'X'
 WHERE SCHEDSTAT = 'N'; SELECT @@ROWCOUNT", 'ac_result')
>
>It returns 1 and the table is getting updated but I don't get a resulting cursor. If I separate the two SQL out I do get a cursor. But if I separate them out couldn't I run the risk of getting a wrong value?
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform