Access and equiv of Transact-SQL's Nolock hint?

  • Thread starter Darrell Grissen
  • Start date
D

Darrell Grissen

Hi,

I am working on a project and plan to use Access to
connect to SQL server. The developers are worried about
time-outs... so my question is - Does Access have an
equivalent of Transact-SQL's Nolock hint? If so, what is
the syntax and/or where can I find more information about
it?

Thanks,

Darrell
 
M

MGFoster

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Use pass-thru queries w/ the T-SQL NOLOCK hint.

Don't you think that's kinda dangerous - reading an uncommitted
transaction might result in invalid data returned in your query 'cuz an
uncommitted transaction might be rolled back.

Why don't you just test your queries in the SQL Query Analyzer & see
what their times are, then set the Access query Timeout property to a
little over that time?

--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQO2IeYechKqOuFEgEQIsmQCfU2gpA1Uks33So9uYKB5PfBNRGTMAn3dM
f7IVxCFwmePSbtjaV+ugzRkF
=XXqW
-----END PGP SIGNATURE-----
 
P

Pat Hartman

Open a query in design view and look at its properties.
One of them is ODBC timeout which may be what you're
looking for.
 
R

Rick Brandt

MGFoster said:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Use pass-thru queries w/ the T-SQL NOLOCK hint.

Don't you think that's kinda dangerous - reading an uncommitted
transaction might result in invalid data returned in your query 'cuz an
uncommitted transaction might be rolled back.

Why don't you just test your queries in the SQL Query Analyzer & see
what their times are, then set the Access query Timeout property to a
little over that time?

Depends (as usual). I have had to use NOLOCK on a few occasions where I
was using a data table as the source of a ComboBox RowSource. Without
NOLOCK use of the ComboBox would impose a lock on the source table until
the last row of the list was accessed. Other users trying to make edits
against that table would then be blocked. Adding NOLOCK cured the problem.
 
M

MGFoster

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

It might be better to use a stored procedure as the data source of the
ComboBox/ListBox. Another solution is to download the necessary data to
a temp table in Access & use those tables as the data source of the
Combo/List boxes.

--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBQO9fSYechKqOuFEgEQJx7wCfakngqzUPYqTPP8Gzp0wqzRvJGM4Ani7H
+gS42v4/Nxv36vzAk49W3waR
=8Mx+
-----END PGP SIGNATURE-----
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top