?
Solved

Add no lock to a select statement in access

Posted on 2008-06-16
8
Medium Priority
?
1,810 Views
Last Modified: 2012-05-05
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
Comment
Question by:meteorelec
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
8 Comments
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 21794039
NOLOCK is only MS SQL Server syntax, and cannot be used in access queries..
0
 
LVL 1

Expert Comment

by:1nmisri
ID: 21794088
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
 
LVL 2

Author Comment

by:meteorelec
ID: 21794108
Really, even when i use the sql view as apposed to the design view?
0
Learn how to optimize MySQL for your business need

With the increasing importance of apps & networks in both business & personal interconnections, perfor. has become one of the key metrics of successful communication. This ebook is a hands-on business-case-driven guide to understanding MySQL query parameter tuning & database perf

 
LVL 2

Author Comment

by:meteorelec
ID: 21794145
So is it not possible to query data in access when it is in use?
0
 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 21794268
how do you run the query? is this a ADP?
0
 
LVL 2

Author Comment

by:meteorelec
ID: 21794388
No i use Access 2003.
0
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 2000 total points
ID: 21794437
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
 
LVL 2

Author Comment

by:meteorelec
ID: 21794592
Thanks thats sorted it,

I'm now using a pass through query
0

Featured Post

Get MySQL database support online, now!

At Percona’s web store you can order your MySQL database support needs in minutes. No hassles, no fuss, just pick and click. Pay online with a credit card.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I'm trying, I really am. But I've seen so many wrong approaches involving date(time) boundaries I despair about my inability to explain it. I've seen quite a few recently that define a non-leap year as 364 days, or 366 days and the list goes on. …
Composite queries are used to retrieve the results from joining multiple queries after applying any filters. UNION, INTERSECT, MINUS, and UNION ALL are some of the operators used to get certain desired results.​
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question