hide duplicate fields in related records

G

geexcess

I have a query that is showing info like this:
Name Thing Date
A A1 MAY
A A2 MAY
A A3 MAY
B B1 JUNE
B B2 JUNE
B B3 JUNE
B B4 JUNE
B B5 JUNE
C C1 JUNE
C C2 JUNE
C C3 JUNE
C C4 JUNE
Now I want to get rid of the duplicates so it looks like this:
Name Thing Date
A A1 MAY
A2
A3
B B1 JUNE
B2
B3
B4
B5
C C1 JUNE
C2
C3
C4
I tried HideDuplicates for the "Date" but it blocks JUNE from being displayed
again in ANY of the records. I'm looking for some code (I think) that says:
If a record has a duplicate "Name" then hide the records "Date" field. I'm
not sure if this would best be done in a query or report. Please help.
 
T

tina

display the query's records in a report, where you can set a control's
HideDuplicates property to Yes, which will give the result you want.

and please, have a realistic expectation of response time in the
newsgroups - this is not a helpline, but a peer-to-peer forum where private
individuals (not Microsoft employees) ask and answer questions about Access
and help each other. once you've posted a question, recommend you wait at
least a day for a response before posting again; certainly 19 minutes is not
realistic.

hth
 
G

geexcess

Sorry, I don't know what you mean about 19 minutes. Is 11:59pm on Saturdays a
deadline of some sort? I wasn't expecting an answer before midnight. There
was no rush. I have obviously upset you and probably others as well. That was
not my intention. I hope you or someone else will take a closer look at my
request. HideDuplicates hides too much.
display the query's records in a report, where you can set a control's
HideDuplicates property to Yes, which will give the result you want.

and please, have a realistic expectation of response time in the
newsgroups - this is not a helpline, but a peer-to-peer forum where private
individuals (not Microsoft employees) ask and answer questions about Access
and help each other. once you've posted a question, recommend you wait at
least a day for a response before posting again; certainly 19 minutes is not
realistic.

hth
I have a query that is showing info like this:
Name Thing Date
[quoted text clipped - 28 lines]
If a record has a duplicate "Name" then hide the records "Date" field. I'm
not sure if this would best be done in a query or report. Please help.
 
M

Michel Walsh

hi,

Unless you can easily spot the previous record (accordingly to the full
date_time), you are better in a report where you will group by (in the
report, NOT in the query) on Name, then on Date. The report wizard can do
all the job for you, if you select the one that hide the dup. in the same
group, except that in the end, you will exchange the position (horizontally)
between the Thing column and the Date column.



Hoping it may help,
Vanderghast, Access MVP
 
G

Guest

OK, I solved this issue with a report. The grouping option that Michel
mentioned previously. I grouped the records by mailbox. Then I could hide any
duplicates for each record associated with the mailbox. Exactly what I
wanted. Thank you for your assistance, Michel. I definitely learned a few
things!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top