Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Progress bar while extracting data via odbc
Message
 
To
30/05/2008 12:47:57
General information
Forum:
Visual FoxPro
Category:
Client/server
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
DB2
Miscellaneous
Thread ID:
01320603
Message ID:
01320630
Views:
15
>thanks Borislav, but this dont work due "hits" table is just storing records each "milisecond?" that sqlexec is not returning data
>and the first sql to count records is not helping :) this table has 4million in some clients...
>
>>>
>
>=SQLExec(nn,"SELECT COUNT(*) AS Cnt FROM products","MyResult1")
>** Error handling here
>SQLSetProp(nn,"Asynchronous",.T.)
>
>xx=1
>do while NOT USED("MyResult") && SQLEXEC() will return 0 till all records
>                              && fetched and returned to client. So,
>                              && when you want to fetch, just wait till alias created with
>                              && first FetchSize number of records (300 in this sample)
>   =SQLExec(nn,"SELECT * FROM products","MyResult")
>   INSERT INTO hits values(xx) &&here i need to put something like 23%,24%, etc.
>   WAIT WINDOW NOWAIT TRANSFORM(RECCOUNT([Hints])/MyResult1.Cnt * 100)+[ %]
>
=SQLExec(nn,"SELECT COUNT(*) AS Cnt FROM products","MyResult1")
** Error handling here
SQLSetProp(nn,"Asynchronous",.T.)

xx=1
do while NOT USED("MyResult") && SQLEXEC() will return 0 till all records
                              && fetched and returned to client. So,
                              && when you want to fetch, just wait till alias created with
                              && first FetchSize number of records (300 in this sample)
   =SQLExec(nn,"SELECT * FROM products","MyResult")
   INSERT INTO hits values(xx) &&here i need to put something like 23%,24%, etc.
   WAIT WINDOW NOWAIT TRANSFORM(xx*10000/MyResult1.Cnt * 100)+[ %]
   xx = xx +1
ENDDO
?
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