Solved

IN syntax in access

Posted on 2011-02-19
6
277 Views
Last Modified: 2012-05-11
is t-sql's IN, NOT IN syntax work in access sql the same way?

thanks
0
Comment
Question by:anushahanna
6 Comments
 
LVL 11

Accepted Solution

by:
rowansmith earned 167 total points
ID: 34936078
Yes.  It is exactly the same.

See : http://msdn.microsoft.com/en-us/library/bb208859(v=office.12).aspx

-Rowan
0
 
LVL 11

Expert Comment

by:rowansmith
ID: 34936086
However I should clarify that you can not use "in" with another select statement in access (as you can with T-SQL).

eg:  select a from tabX where a in (select a from tabY)

Will not work in access.
0
 
LVL 77

Assisted Solution

by:peter57r
peter57r earned 167 total points
ID: 34936135
rowansmith,

select a from tabX where a in (select a from tabY)

...will definitely work in Access, assuming the 'a' fields are compatible.
0
U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

 
LVL 84

Assisted Solution

by:Scott McDaniel (Microsoft Access MVP - EE MVE )
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 166 total points
ID: 34937119
Ditto what Peter said; I use the IN keyword frequently in Access with a sub-select.
0
 
LVL 11

Expert Comment

by:rowansmith
ID: 34938449
Agreed. My mistake.
0
 
LVL 6

Author Comment

by:anushahanna
ID: 34939972
Thank you experts.
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

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

The first two articles in this short series — Using a Criteria Form to Filter Records (http://www.experts-exchange.com/A_6069.html) and Building a Custom Filter (http://www.experts-exchange.com/A_6070.html) — discuss in some detail how a form can be…
It took me quite some time to sort out all the different properties of combo and list boxes available from Visual Basic at run-time. Not that the documentation is lacking: the help pages are quite thorough and well written. The problem was rather wh…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

867 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now