Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Best way on Updating a SQL file
Message
From
19/03/2004 15:48:13
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Best way on Updating a SQL file
Miscellaneous
Thread ID:
00888043
Message ID:
00888043
Views:
56
Hi everyone,

I have been having trouble updating a SQL table with RV. I have a table Myfoo with and index and it seems to talk a while here what I have:


Index is currently on Myitem, and I think I need to have on Myorder as well.

SELECT Myfoo

REPLACE ALL status WITH "4" FOR orderno = lc_Myorderno
=tableupdate(.t.)
REQUERY()

This will be really slow on a large file.

I was thinking on using a SCAN ENDSCAN with a new index setup for Myfoo, on ORDERNO.

lc_MyfooOrder = lc_myorderno
SELECT Myfoo
REQUERY()

SCAN WHILE orderno = lc_Myorderno
REPLACE status WITH "4"
=tableupdate(.t.)
ENDSCAN
REQUERY()

Im I on the right path here? BTW, having touble highligting the code to so you can visually see that that it is code. I still learning my way around UT.

Any help is greatly appreciated.

Craig
Next
Reply
Map
View

Click here to load this message in the networking platform