Solved

IN syntax in access

Posted on 2011-02-19
6
278 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
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 
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

Enterprise Mobility and BYOD For Dummies

Like “For Dummies” books, you can read this in whatever order you choose and learn about mobility and BYOD; and how to put a competitive mobile infrastructure in place. Developed for SMBs and large enterprises alike, you will find helpful use cases, planning, and implementation.

Question has a verified solution.

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

Experts-Exchange is a great place to come for help with solutions for your database issues, and many problems are resolved within minutes of being posted.  Others take a little more time and effort and often providing a sample database is very helpf…
It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
Familiarize people with the process of utilizing SQL Server views from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Microsoft Access…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …

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