Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
ADO, RemoteView, RDO, DAO, SQLPassthrough. which is fas
Message
From
06/07/1999 08:50:27
 
 
To
05/07/1999 21:11:55
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00237613
Message ID:
00237686
Views:
11
>Hi,
> Can anybody tell me which of the method of accessing remote table or database is faster and better ? Please provide details in comparison or URL.
> Method:
> DAO, ADO, RDO, RemoteView, SQLPassthrough.....
>
>Thank you

What kind of remote data will you be accessing? Also remember that DAO, ADO, and RDO are object models that sit on top of either the Jet engine, ODBC, or OLEDB.

I'll tell you what I know about using ADO, Remote views, and SPT against SQL Server 7.0 using the latest drivers.

I used the SQL Profiler to capture the commands that were sent to SQL Server. ADO/OLEDB submits queries using the sp_executesql system stored procedure. This stored procedure required that the caller identiy parameters. With this information, SQL Server can cache the query plan and reuse it the next time the query is called. Remote views also exhibit this behavior. Which makes sense since our applications are likely to submit multiple insert/update/delete queries in a single TABLEUPDATE().

SPT does just that. It passed the query, as is, to SQL Server. The query was not wrapped within a call to sp_executesql.

Which is faster? We'll for a single execute of a query, SPT will be faster because it doesn't have the overhead of calling sp_executesql. But if you we're going to make multiple calls using the same query but with different parameters, ADO or remote views would be faster since SQL Server would not have to optimize and recompile the query each time.

Now something that I didn't explore (and can't right now) is SQLPrepare(). SQLPrepare was designed for those circumstances where you needed to make multiple submissions of the same query and just needed to change some of the parameters. Maybe someone else can check this. I have to call a client.

-Mike
Michael Levy
MCSD, MCDBA
ma_levy@hotmail.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform