Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
View VS. Pass-through Question
Message
De
17/08/2006 09:26:59
 
 
À
17/08/2006 08:21:59
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows NT
Database:
MS SQL Server
Divers
Thread ID:
01146313
Message ID:
01146344
Vues:
21
>I have only basic knowledge of Access but the other day I was working with someone on a project and they were using Access 97. They too did not know anything about pass-though technology. But, I noticed it was one of the menu choices. It looked like you could run the query in the default mode or just make a menu selection and run it in PT mode. No change in the code, not special setup strings, just click and go. We tried this and the queries she had designed seemed to run about 20% faster. This experience got me to thinking about VFP and PT?
>
>I've always used VFP views because it is so much simpler, due to having the View Designer and just referencing them with a USE statement. So, I guess the main thing I'm trying to figure out is if I should start hand coding PT statements or continuing using views. I know that the View Designer has limitations but it has always met my needs about 99% of the time. When it doesn't, I've cut & pasted the SQL statement into a PRG and altered it to meet my needs.
>
>Somewhere, I've read that sending a SQL statements via pass-through will execute faster than using the same SQL statement in a view because the SQL statement is actually processed on the back-end server and only the matching record set sent back to VFP. Is this correct (see next question)?

No, when using remote views, the query must be passed to the backend database for processing.

>
>Also, I've read that a "view" is merely a wrapper around "pass-through technology." If this is true, then wouldn't they both have the same efficency, i.e. speed of returning records?

That's basically true

>If there is a significan performance difference, how much of a hit can you expect to take using views vs. PT, i.e., 10%, 20%, etc.?

It depends on what exactly you're doing.

>
>In VPF, if there is a significant difference between view & PT in terms of performance, then why didn't the VFP development team give you the option of using PT by just "checking" a menu choice on the View Desginer, like in Access 97?

That's a question for the people that were on the team when the decision was made.

>
>Do you know of anyone who has created a tool that takes a view and writes it out as a PRG in PT coding?

Look at GenDBC in your VFP\Tools folder.

You may also want to look at Andy Kramek's data classes at www.tightlinecomputers.com
Craig Berntson
MCSD, Microsoft .Net MVP, Grape City Community Influencer
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform