473,473 Members | 1,569 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Omitting Records in Union Query?

Have two base queries used for mailing labels with
id,name,address,city,state,zip that are combined via a union query.
One base query uses home address; the other base query uses biz
address. I only want one label per person. In a few cases, I have a
record with both a home address and a biz address, which I don't want
in the labels. How or can I make the union query omit an id in the biz
address base query IF that same id has a record in the base home
address query? I'm drawing a blank on this one. Thanks for any
advice.
Nov 12 '05 #1
2 2254
Go to the database window, click on Queries and click on New. You'll see you can
create an unmatched query. Use that option to create a new query and find all
the records in your biz base query that do not match any records in your base
home address query. Then build a new union query combining the new query with
the base home address query. Your new union query will not now have any
duplicate records.

--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
re******@pcdatasheet.com
www.pcdatasheet.com
"M Stery" <ms****@soon.com> wrote in message
news:8b*************************@posting.google.co m...
Have two base queries used for mailing labels with
id,name,address,city,state,zip that are combined via a union query.
One base query uses home address; the other base query uses biz
address. I only want one label per person. In a few cases, I have a
record with both a home address and a biz address, which I don't want
in the labels. How or can I make the union query omit an id in the biz
address base query IF that same id has a record in the base home
address query? I'm drawing a blank on this one. Thanks for any
advice.

Nov 12 '05 #2
Perfect. Thanks so much.

"PC Datasheet" <sp**@nospam.spam> wrote in message news:<3d***************@newsread3.news.atl.earthli nk.net>...
Go to the database window, click on Queries and click on New. You'll see you can
create an unmatched query. Use that option to create a new query and find all
the records in your biz base query that do not match any records in your base
home address query. Then build a new union query combining the new query with
the base home address query. Your new union query will not now have any
duplicate records.

Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: M Stery | last post by:
Have two base queries used for mailing labels with id,name,address,city,state,zip that are combined via a union query. One base query uses home address; the other base query uses biz address. I...
0
by: Jason | last post by:
I have a primary form which is used to enter/edit data in a table named Test_Results. On this primary form there is a subform which displays site addresses. This subform is linked to the primary...
1
by: snOOp | last post by:
I am trying to combine the data from two similar tables into one query, but I need for all of the records from both tables to show up and I want the ones that have matching 'emplid' to be combined...
1
by: Brian | last post by:
I'm trying to find a way to search multiple tables for the same record. Say I have 3 tables all with a name column, I need to search all 3 tables and find matching names. Is there an easy way to...
2
by: mattytee123 | last post by:
I have about 20 tables, of which I would like to do a union query and count of how many of each different code there is? The simplified verson of the table is structured like this. Code ...
2
by: Zeljko | last post by:
I'm creating Address book. Header of the main form (frmAddress) contains combo box (cboFilter) to filter records by Occupation on main Form(Ocupation1). That's working. Combo box also have "Show...
1
by: aayushi22 | last post by:
Hi Need your expert help on the following i have a table with the following records EMP ID Req No Candidate name 1 candidate status 1 candidate name 2
2
kcdoell
by: kcdoell | last post by:
Hello: I am trying to create a union query but do not have a lot of experience. Basically I have the below tables: The Tables: Table Name = tblPrior CreditRegIDFK; Number; Foreign Key...
0
by: Hamayun Khan | last post by:
Hi All I am using the following query to select records from two tables. Select JobTitle,JobDesc,Scraped,logoimage,JobPostID,SchoolID,web,MemType,InstitutionName,PayScale,LEA,Contract as...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.