duplicating data

G

Guest

I'd like to run a report that might have duplicate data in different parts of
the report.

I'd like the format to simply be:

Category 1 (Bold header)
field 1
field 2
field 3

Category 2 (Bold header)
field 1
field 2
field 3

The categories are check boxes in the same table that holds the rest of the
data. Some datasets will have multiple categories checked. I'd like to be
able to have the data presented under each category when that checkbox has
been checked.

Does this need more than one query? There are a total of 6 categories and
several hundred records.

michael munson
(e-mail address removed)
 
D

Duane Hookom

And your table structure is...?
I think you can use a union query to normalize your table structure. Then
report from the union query.
 
G

Guest

Duane Hookom said:
And your table structure is...?

ID
Checkbox 1
Checkbox 2
Checkbox 3
Checkbox 4
Checkbox 5
Checkbox 6
State
City
Title
Author
URL
SortDate


I think you can use a union query to normalize your table structure. Then
report from the union query.

Can you offer an example of what you mean please?

thank you.

michael munson
(e-mail address removed)
 
D

Duane Hookom

I really don't understand your Field 1, Field 2, Field 3. Did you really
mean different records or is there only one record with three fields. You
can get started by creating a normalized view of your table with a union
query like:

SELECT ID, 1 as CheckBox
FROM tblNoName
WHERE [CheckBox 1]= True
UNION ALL
SELECT ID, 2
FROM tblNoName
WHERE [CheckBox 2]= True
UNION ALL
SELECT ID, 3
FROM tblNoName
WHERE [CheckBox 3]= True
UNION ALL
SELECT ID, 4
FROM tblNoName
WHERE [CheckBox 4]= True
UNION ALL
SELECT ID, 5
FROM tblNoName
WHERE [CheckBox 5]= True
UNION ALL
SELECT ID, 6
FROM tblNoName
WHERE [CheckBox 6]= True;
 

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