Welcome to the { mindfrost82.com } forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact contact us.

Go Back   { mindfrost82.com } > Gadget Corner > Tech Newsgroups > Microsoft > MS Office > Access

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 08-11-2008, 05:40 PM
=?Utf-8?B?QnVyZ2hSb2Nrcw==?=
 
Posts: n/a
Newbie Help - Probably a simple query

Hi all,

I have two columns of data. Column A is names and column B is dates. There
are approximately 33k records of names corresponding to dates. While most of
the names appear only once, there are times when the name appears multiple
times. What I would like is a query that only shows me names when they
appear more than once. If a name only appears once then I do not want it, or
the corresponding date, to be shown in the results. I would like that query
to include the date that the name appears as well.

Can someone assist with this? Many thanks in advance.

Bill
Reply With Quote
  #2 (permalink)  
Old 08-11-2008, 06:53 PM
pietlinden@hotmail.com
 
Posts: n/a
Re: Newbie Help - Probably a simple query

On Aug 11, 11:40*am, BurghRocks <BurghRo...@discussions.microsoft.com>
wrote:
> Hi all,
>
> I have two columns of data. *Column A is names and column B is dates. *There
> are approximately 33k records of names corresponding to dates. *While most of
> the names appear only once, there are times when the name appears multiple
> times. *What I would like is a query that only shows me names when they
> appear more than once. *If a name only appears once then I do not want it, or
> the corresponding date, to be shown in the results. *I would like that query
> to include the date that the name appears as well.
>
> Can someone assist with this? *Many thanks in advance.
>
> Bill


SELECT tPerson.PersonName, Count(Appointment.ApptDate) AS
CountOfApptDate
FROM tPerson INNER JOIN Appointment ON tPerson.PersonID =
Appointment.PersonID
GROUP BY tPerson.PersonName
HAVING (((Count(Appointment.ApptDate))>1));
Reply With Quote
  #3 (permalink)  
Old 08-11-2008, 07:14 PM
John Spencer
 
Posts: n/a
Re: Newbie Help - Probably a simple query

Use the find duplicates query wizard.

In the database window, on the queries tab
--Select Insert: Query from the Menu
--In the dialog box, Select Find Duplicates Query Wizard
--In the next window, select your Table or Query
--In the next window, select the field with duplicates
--In the next window, select any additional fields you want to display.
--In the next window, Name your query and click Finish

John Spencer
Access MVP 2002-2005, 2007-2008
The Hilltop Institute
University of Maryland Baltimore County

pietlinden@hotmail.com wrote:
> On Aug 11, 11:40 am, BurghRocks <BurghRo...@discussions.microsoft.com>
> wrote:
>> Hi all,
>>
>> I have two columns of data. Column A is names and column B is dates. There
>> are approximately 33k records of names corresponding to dates. While most of
>> the names appear only once, there are times when the name appears multiple
>> times. What I would like is a query that only shows me names when they
>> appear more than once. If a name only appears once then I do not want it, or
>> the corresponding date, to be shown in the results. I would like that query
>> to include the date that the name appears as well.
>>
>> Can someone assist with this? Many thanks in advance.
>>
>> Bill

>
> SELECT tPerson.PersonName, Count(Appointment.ApptDate) AS
> CountOfApptDate
> FROM tPerson INNER JOIN Appointment ON tPerson.PersonID =
> Appointment.PersonID
> GROUP BY tPerson.PersonName
> HAVING (((Count(Appointment.ApptDate))>1));

Reply With Quote
  #4 (permalink)  
Old 08-11-2008, 07:47 PM
=?Utf-8?B?QnVyZ2hSb2Nrcw==?=
 
Posts: n/a
Re: Newbie Help - Probably a simple query

Works great, thank you both very much!

Bill

"John Spencer" wrote:

> Use the find duplicates query wizard.
>
> In the database window, on the queries tab
> --Select Insert: Query from the Menu
> --In the dialog box, Select Find Duplicates Query Wizard
> --In the next window, select your Table or Query
> --In the next window, select the field with duplicates
> --In the next window, select any additional fields you want to display.
> --In the next window, Name your query and click Finish
>
> John Spencer
> Access MVP 2002-2005, 2007-2008
> The Hilltop Institute
> University of Maryland Baltimore County
>
> pietlinden@hotmail.com wrote:
> > On Aug 11, 11:40 am, BurghRocks <BurghRo...@discussions.microsoft.com>
> > wrote:
> >> Hi all,
> >>
> >> I have two columns of data. Column A is names and column B is dates. There
> >> are approximately 33k records of names corresponding to dates. While most of
> >> the names appear only once, there are times when the name appears multiple
> >> times. What I would like is a query that only shows me names when they
> >> appear more than once. If a name only appears once then I do not want it, or
> >> the corresponding date, to be shown in the results. I would like that query
> >> to include the date that the name appears as well.
> >>
> >> Can someone assist with this? Many thanks in advance.
> >>
> >> Bill

> >
> > SELECT tPerson.PersonName, Count(Appointment.ApptDate) AS
> > CountOfApptDate
> > FROM tPerson INNER JOIN Appointment ON tPerson.PersonID =
> > Appointment.PersonID
> > GROUP BY tPerson.PersonName
> > HAVING (((Count(Appointment.ApptDate))>1));

>

Reply With Quote
Reply

  { mindfrost82.com } > Gadget Corner > Tech Newsgroups > Microsoft > MS Office > Access


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT. The time now is 05:02 PM.


Powered by vBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.1.0 ©2007, Crawlability, Inc.
© 1999-2008 mindfrost82.com v11.0


Sponsors:
vShare YouTube Clone | Credit Card | Download movies | Car Loan | vShare YouTube Clone



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114