Solved

Microsoft Access - Query

Posted on 2011-03-17
6
269 Views
Last Modified: 2012-05-11
I have two queries within access.  Query 1 - contains all accounts that have been opened from Jan 1 - Dec 31, 2010.   Query 2 contains all accounts opened from Jan 1 2010 - March 15 2011.  Is there a way to identify the new accounts that have been opened?   Those that are new will not be duplicated on Query 2.  Is there a way to determine which ones have not been duplicated?
0
Comment
Question by:ArisaAnsar
[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
6 Comments
 
LVL 11

Expert Comment

by:wrmichael
ID: 35159552
Do you have table structures and query?

depends on the data available to you.

0
 
LVL 40

Expert Comment

by:als315
ID: 35159564
Left join your queries (Account field): select all from Query 1 with criteria: is Null for any field from Query 2
0
 
LVL 1

Expert Comment

by:gmartinnc
ID: 35159586
It seems your dates are a little wonky.  Is the second range Jan 1 2011 - March 15 2011?

If so, I think you are asking for something like this:
SELECT * FROM Query2 WHERE OpenDate NOT IN (SELECT OpenDate FROM Query1)

Is that correct?
0
Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

 
LVL 10

Accepted Solution

by:
Luke Chung earned 500 total points
ID: 35160100
What you need is a "non-in" query, otherwise known as an Outer Join between your two queries.

We have a paper Microsoft Access/SQL Server Query Tip: Finding Records in One Table but Not Another with "Not In" Queries here:  
http://www.fmsinc.com/microsoftaccess/query/outer-join/index.html

Hope this helps.
0
 

Author Closing Comment

by:ArisaAnsar
ID: 35168516
The Microsoft Access/SQL Server Query Tip is incredibly helpful and got me to the solution.  Thank you very much.
0
 
LVL 1

Expert Comment

by:gmartinnc
ID: 35190601
Hmmm.  seems to me I just said that.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

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

AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…

688 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