Sorting & Grouping Problem

R

Ruth

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
D

Duane Hookom

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]
 
R

Ruth

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

Duane Hookom said:
Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
D

Duane Hookom

If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

Duane Hookom said:
Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
R

Ruth

Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



Duane Hookom said:
If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

Duane Hookom said:
Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
D

Duane Hookom

Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



Duane Hookom said:
If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
R

Ruth

I have a table which has 5 columns:-
Group Name
Group Category
Group Sub-Category
Code Start
Code End

Duane Hookom said:
Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



Duane Hookom said:
If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
D

Duane Hookom

Try create a query like:
SELECT [Group Name], Min([Code Start]) as GroupSort
FROM [tblWith5Columns]
GROUP BY [Group Name];

Then add this query to your report's record source and use the GroupSort
column/field as your primary sorting field/expression.
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
I have a table which has 5 columns:-
Group Name
Group Category
Group Sub-Category
Code Start
Code End

Duane Hookom said:
Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



:

If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
R

Ruth

Right, I created the query, and added it to the record's record source which
makes it sort alphabetically by Group Name.

How do I make the GroupSort column/field my primary sorting
field/expression? I have been into the Sorting and Grouping box and added
GroupSort - Ascending and moved it to the top of the list but this just adds
in headings above every Group Sub-Category and Group Category item - instead
of "grouping" them together.

Duane Hookom said:
Try create a query like:
SELECT [Group Name], Min([Code Start]) as GroupSort
FROM [tblWith5Columns]
GROUP BY [Group Name];

Then add this query to your report's record source and use the GroupSort
column/field as your primary sorting field/expression.
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
I have a table which has 5 columns:-
Group Name
Group Category
Group Sub-Category
Code Start
Code End

Duane Hookom said:
Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



:

If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
D

Duane Hookom

When you view the Group Sorting totals query, do you see the values in
GroupSort that you would like to sort your groups by?

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Right, I created the query, and added it to the record's record source which
makes it sort alphabetically by Group Name.

How do I make the GroupSort column/field my primary sorting
field/expression? I have been into the Sorting and Grouping box and added
GroupSort - Ascending and moved it to the top of the list but this just adds
in headings above every Group Sub-Category and Group Category item - instead
of "grouping" them together.

Duane Hookom said:
Try create a query like:
SELECT [Group Name], Min([Code Start]) as GroupSort
FROM [tblWith5Columns]
GROUP BY [Group Name];

Then add this query to your report's record source and use the GroupSort
column/field as your primary sorting field/expression.
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
I have a table which has 5 columns:-
Group Name
Group Category
Group Sub-Category
Code Start
Code End

:

Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



:

If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
R

Ruth

When I view the query the sort is perfectly how I want it. But when I come
to trying to group by Group Name, Category and Sub-Category it all goes
wrong! Is there any way I can keep items in this order and have a heading
for Group Name under which all items in that group are listed without
repeating the Group Name heading each time or am I just being too pedantic??!

Duane Hookom said:
When you view the Group Sorting totals query, do you see the values in
GroupSort that you would like to sort your groups by?

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Right, I created the query, and added it to the record's record source which
makes it sort alphabetically by Group Name.

How do I make the GroupSort column/field my primary sorting
field/expression? I have been into the Sorting and Grouping box and added
GroupSort - Ascending and moved it to the top of the list but this just adds
in headings above every Group Sub-Category and Group Category item - instead
of "grouping" them together.

Duane Hookom said:
Try create a query like:
SELECT [Group Name], Min([Code Start]) as GroupSort
FROM [tblWith5Columns]
GROUP BY [Group Name];

Then add this query to your report's record source and use the GroupSort
column/field as your primary sorting field/expression.
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I have a table which has 5 columns:-
Group Name
Group Category
Group Sub-Category
Code Start
Code End

:

Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



:

If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 
D

Duane Hookom

"trying to group by Group Name, Category and Sub-Category" did you try to
sort/group by the GroupSort column, then Category, and finally Sub-Category?

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
When I view the query the sort is perfectly how I want it. But when I come
to trying to group by Group Name, Category and Sub-Category it all goes
wrong! Is there any way I can keep items in this order and have a heading
for Group Name under which all items in that group are listed without
repeating the Group Name heading each time or am I just being too pedantic??!

Duane Hookom said:
When you view the Group Sorting totals query, do you see the values in
GroupSort that you would like to sort your groups by?

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


Ruth said:
Right, I created the query, and added it to the record's record source which
makes it sort alphabetically by Group Name.

How do I make the GroupSort column/field my primary sorting
field/expression? I have been into the Sorting and Grouping box and added
GroupSort - Ascending and moved it to the top of the list but this just adds
in headings above every Group Sub-Category and Group Category item - instead
of "grouping" them together.

:

Try create a query like:
SELECT [Group Name], Min([Code Start]) as GroupSort
FROM [tblWith5Columns]
GROUP BY [Group Name];

Then add this query to your report's record source and use the GroupSort
column/field as your primary sorting field/expression.
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I have a table which has 5 columns:-
Group Name
Group Category
Group Sub-Category
Code Start
Code End

:

Are the values 0000 - 0999 stored in the table you want to use as your
primary grouping in your report? If not, where are these values stored and
how are they related to the table/field you want to use as your primary
grouping in your report?
--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Not quite! I don't want it to sort by code only within groups, I want the
whole report to print in code order - if possible - so that we can easily see
where there are any spaces.

So, for example I want it to start with the group that ranges from 0000 -
0999. Then the group 1000 - 1999 etc.

Then within each group I want the sub groups to print in code order too.
Some of these are sub-divided too - so they want to run in code order also.

Does that make sense?



:

If I understand correctly you want a primary group on the Group Name however
the sequence of the Group Name display should be based on the min or max of a
field in a child record??? For instance, if you have a table of employees and
their families, you want to group them by family but the order should be
based on the age of the oldest child in each family.

If this is correct, please describe which field from a related table and
min/max that describes the order of your primary grouping.

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

Thanks for your reply Duane.

If I set the sorting and grouping in that order it looks better, but it
sorts by Group Name alphabetically, rather than follows in number order.

:

Are your sorting and grouping field/expressions set to:

[Group Name]
[Group Category]
[Group Sub-category]

--
Duane Hookom
Microsoft Access MVP
If I have helped you, please help me by donating to UCP
http://www.access.hookom.net/UCP/Default.htm


:

I am trying to create a Grouping Codes report that looks like this:-

Code Start Code End
Group Name
Group Category
Group Sub-category x y

so that it produces:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999
Paper Products 0100
0199
etc.

The codes for each group are contained within a range and I want the report
to sort by the code so that it starts with the group with the codes beginning
with 0 then ends with the group with the codes beginning with 9.

I've got it to sort by code, but for every Group Sub-Category it repeats the
Group Name & Group Category so I have something that looks like this:-

HARDWARE Code Start Code End
Cleaning & Catering
Laundry 0000
0999

HARDWARE
Cleaning & Catering
Paper Products 0100 0199

I've played around with grouping and sorting and am not getting anywhere -
any advice would be gratefully received.
 

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