• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1818
  • Last Modified:

Add no lock to a select statement in access

I have a select statement in access shown in the snippet,

how do i add no lock
SELECT scheme_opdetm.*, scheme_opheadm.order_no
FROM scheme_opheadm LEFT JOIN scheme_opdetm ON scheme_opheadm.order_no = scheme_opdetm.order_no
WHERE (((scheme_opheadm.order_no)="947579"));

Open in new window

0
meteorelec
Asked:
meteorelec
  • 4
  • 3
1 Solution
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
NOLOCK is only MS SQL Server syntax, and cannot be used in access queries..
0
 
1nmisriCommented:
This where I have put it in the other SQL queries

SELECT scheme_opdetm.*, scheme_opheadm.order_no
FROM scheme_opheadm(nolock)
 LEFT JOIN scheme_opdetm ON scheme_opheadm.order_no = scheme_opdetm.order_no
WHERE (((scheme_opheadm.order_no)="947579"));
0
 
meteorelecAuthor Commented:
Really, even when i use the sql view as apposed to the design view?
0
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

 
meteorelecAuthor Commented:
So is it not possible to query data in access when it is in use?
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
how do you run the query? is this a ADP?
0
 
meteorelecAuthor Commented:
No i use Access 2003.
0
 
Guy Hengel [angelIII / a3]Billing EngineerCommented:
so, you create a plain query in your access, on plain access tables?
or is this a PassThrough query to sql server tables?

if its plain access query ... NOLOCK cannot be used.
0
 
meteorelecAuthor Commented:
Thanks thats sorted it,

I'm now using a pass through query
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

  • 4
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now