[AccessD] Basic Question

Keith Williamson Kwilliamson at RTKL.com
Wed May 27 16:04:38 CDT 2009


That's what I thought, originally.  I had one query that was only
providing results if BOTH selects existed.  This threw me for a loop.  I
wound up going another way...but was a bit shaken, as I've used this
method a number of times.  I went back and checked a couple other of my
union joins.....and they were yielding results for EITHER select.
So...I don't know what was going wrong with that other one.  The big
issue is that because of the missing data...I was over-stating our
Intake of projects, by about $1.5 million.  I'm not looking forward to
telling the BOD that we actually had $1.5 million less intake of
projects, then I was reporting.....every dollar counts, these days.   :)

Keith Williamson | Associate, Asst. Controller | kwilliamson at rtkl.com 

RTKL Associates Inc. | 901 South Bond St. | Baltimore, MD  21231

410.537.6098 Direct | 410.276.4232 Fax | www.rtkl.com


-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Drew Wutka
Sent: Wednesday, May 27, 2009 3:03 PM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Basic Question

Hmmm, actually Union queries are distinct row by default, so if there is
matching data between any of the 'parts' of a union query, it should
only show up once.

Drew

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Keith
Williamson
Sent: Wednesday, May 27, 2009 12:10 PM
To: Access Developers discussion and problem solving
Subject: [AccessD] Basic Question

Hey gurus,

I have a basic question for you.  Quite a few times, in the past, I've
used Union Join queries to join different queries into common data.  For
instance:

select [WBS1], [SumOfFeeBillingCurrency] as [BeginFee], 0 as [EndFee]
from [qryReportingBacklogFeeBegin]

UNION select [WBS1], 0 as [BeginFee], [SumOfFeeBillingCurrency] as
[EndFee] from [qryReportingBacklogFeeEnd];

Recently I was testing one.....and discovered that my data result was
not correct.  I was thinking that with the union join, if one dataset
did not have matching data, to the other...I would only get one line of
data.  Otherwise, I should get two lines....which I then summarized in
another query of this union join.  However, I found that I only got data
from the datasets, where the select occurred in BOTH sets...([WBS1], in
the above scenario.)  Is that right??  

Keith Williamson | Associate, Asst. Controller | kwilliamson at rtkl.com 

RTKL Associates Inc. | 901 South Bond St. | Baltimore, MD  21231

410.537.6098 Direct | 410.276.4232 Fax | www.rtkl.com


------------------------------------------------------------------------
--
The information contained in this communication is confidential, may be
privileged and is intended for the exclusive use of the above named
addressee(s). If you are not the intended recipient(s), you are
expressly prohibited from copying, distributing, disseminating, or in
any other way using any of the information contained within this
communication. If you have received this communication in error, please
contact the sender by telephone at (410) 537-6000 or by response via
e-mail and permanently delete the original email and any copies.

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
The information contained in this transmission is intended only for the
person or entity 
to which it is addressed and may contain II-VI Proprietary and/or II-VI
Business 
Sensitive material. If you are not the intended recipient, please
contact the sender 
immediately and destroy the material in its entirety, whether electronic
or hard copy. 
You are notified that any review, retransmission, copying, disclosure,
dissemination, 
or other use of, or taking of any action in reliance upon this
information by persons 
or entities other than the intended recipient is prohibited.


-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com





More information about the AccessD mailing list