Re: HOWTO?: force optimizer to use a "remote index join" when joining local to remote table

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



If you are using ODBC, you can turn on ODBC tracing
on your workstation - no change to the server at all - to
see the ODBC messages going from Jet to the ODBC driver.
This will work for any ODBC driver or client, since the service
is provided by the ODBC framework, not the driver or client.

ODBC messages take the form of SQL statements. The
syntax is similar to MS SQL Server SQL.

Logging to disk will slow ODBC. Be sure to turn it off
when you are finished.

There is no way to provide 'hints' to Jet.

However, Jet implements actual ODBC SQL (it doesn't cheat
and assume anything about what the driver will accept), which
means that it can only send one Left or Right join per ODBC
statement. For this reason, multi-table queries are faster if they
use only inner joins, and multiple left/right joins are faster if you
use OLEDB. (faster if your server is lightly loaded. Remote joins
load the server, not the workstation)

If your query really is returning only a few lines, make it a snapshot
instead of a dynamic curser. Use another form to do updates and
appends.

(david)

"Malcolm Cook" <malcook@xxxxxxxxxxxxxxxx> wrote in message
news:OFCMISdsHHA.484@xxxxxxxxxxxxxxxxxxxxxxx
They are against a mysql instance running over the net on hardware I don't
control and mirroring it to run the test you're
suggesting (monitoring the actual query sent to the server) is cost
prohibitive.

I really just need to know if there is a way to FORCE the query optimizer
to use the "remote index join". I can tell by monitoring
the performance and the memory usage that it is NOT happening in a
specific case, despite the fact that my local table is "small" (1
row) and my remote table is "large" (many hundreds of thousands).

???

Malcolm

"Sylvain Lafontaine" <sylvain aei ca (fill the blanks, no spam please)>
wrote in message
news:%23dpG3XcsHHA.1728@xxxxxxxxxxxxxxxxxxxxxxx
If your queries are against SQL-Server, it should be easy to see what's
really happening on the server side by using the
SQL-Server Profiler. For Oracle, you will find a similar tool.

--
Sylvain Lafontaine, ing.
MVP - Technologies Virtual-PC
E-mail: sylvain aei ca (fill the blanks, no spam please)


"Malcolm Cook" <malcook@xxxxxxxxxxxxxxxx> wrote in message
news:epE84O5rHHA.4932@xxxxxxxxxxxxxxxxxxxxxxx
I am finding cases where I would expect Access to perform a "remote
index join", and I do WANT it to be performed, but I am sure
it is NOT being performed.

What I want to know is if there is a way to provide a hint to the query
optimizer, or otherwise cause this query strategy to be
taken.

I learned about this by reading "How to optimize Microsoft Access when
using ODBC data sources" -
http://support.microsoft.com/kb/286222 , where it states

"Heterogeneous joins between local tables and remote tables, or between
remote tables in different ODBC data sources. Joins
between small local tables and large remote tables, where the join
column is indexed, may result in a remote index join. In a
remote index join, one query for each row in the local table is sent to
the server, and only the joining rows are returned."

Thanks,

Malcolm







.



Relevant Pages

  • RE: Invalid cursor state when using PRINT in MSSQL
    ... Interesting article but I seriously doubt you are using the ODBC 2.0 MS SQL ... DBD::ODBC does call SQLError immediately after SQLExecute returns ... I was unable to reproduce this with the ODBC 3 MS SQL Server driver ...
    (perl.dbi.users)
  • Re: DTC Fehler
    ... Lege im SQL Server einen Linked Server für die AS/400 an. ... Einstellungen für den Providerstring - vergleiche auch Angaben zum ODBC ... Die Verbindung zur AS/400 wird über den IBM Client Access ...
    (microsoft.public.de.sqlserver)
  • Re: MS Access database to gradually become a server based database - which one ?
    ... Server 2008 Express Edition. ... SQL server is indeed a high performance system, and also a system that can ... Before Microsoft started "really" selling sql server, they rated JET could ... (this ONLY applies to odbc to sql server...you CAN and are FREE to do this ...
    (microsoft.public.access.gettingstarted)
  • ODBC-Verbindung zu {SQL Native Client}(schulelb002) fehlgeschlagen.
    ... Muss ich etwa einen ODBC Driver am Server oder am Client installieren? ... OleDb ist nicht etwa besser oder so... ... den kriegst Du indem Du {SQL Server} durch ersetzt. ...
    (microsoft.public.de.german.entwickler.dotnet.datenbank)
  • Re: DTC Fehler
    ... Auf dem Windows Server ist SQL Server 2000 SP3a und ... wird der Barcode im SQL ... Server abgespeichert und der Trigger ausgelöst (After ... Access Express ODBC to a R510 or later OS/400 system. ...
    (microsoft.public.de.sqlserver)