Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Why the difference?
Message
From
26/06/2001 15:16:26
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Why the difference?
Miscellaneous
Thread ID:
00523778
Message ID:
00523778
Views:
53
I finally give up. I have an application that, when it starts up, creates an sql view, and it opens the view reeeeaaal slow.

It's a simple view - "Create Sql View v_contracts as select * from ctracts". I don't see how it could be any simpler. The data lives on the network. Also I should mention that I pack the database before exiting the application, so that when it starts up again, there are no deleted records in the database itself.

If, from the command window, I type,
Set safety off
open database contracts
set database to contracts
create sql view v_contracts as select * from ctracts
set safety on
use v_contracts nodata
requery('v_contracts')
that last requery line pulls down the 10,000 records in .44 seconds.

Now, if I create a completely empty form, and put those very same lines in the beforeopentables() event of the datasession, compile it into an exe and run it, that last requery line pulls the same 10,000 records down in 8.99 seconds.

The code in the actual application has more to it, but for the purpose of testing, I did the above and kept it as simple as I could.

Can anybody give me a clue what I should be looking for as to why an exe might take so much longer than the command window to get the same records from the same table on the same network using the same code?

Alan
Next
Reply
Map
View

Click here to load this message in the networking platform