Query to combine (group) text data

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Please help with a query grouping project using Access 2003.

Table: (11 records)
Name Loc Approv Action

Jones top
Jones Yes
Jones Go
Smith Stop
Smith Middle
Frank top
Frank No
Frank Jump
Jane Middle
Jane Yes
Jane Stop

The name field is primary and therefore always populated.

I need my query result to look like this (the indent to show the grouping):
The grouping in on the second field.

LOC Name Approved Action

top
Jones Yes Go
Frank No Jump
middle
Smith Stop
Jane Yes Stop

Can the above be done with a query or at least a flat result that I can
group within the report that looks like:
Jones top Yes Go
Smith Middle Stop
Frank top No Jump
Jane Middle Yes Stop


This has been stumpping me for a couple day now - so any help would be much
appreciated.

Thanks,
 
Try:
SELECT [Name], Max(loc) as TheLoc,
Max(Approv) as TheApprov, Max(Action) as MaxAction
FROM [tbl 11 Records]
GROUP BY [Name];
 
Excellent - thank you very much.

Duane Hookom said:
Try:
SELECT [Name], Max(loc) as TheLoc,
Max(Approv) as TheApprov, Max(Action) as MaxAction
FROM [tbl 11 Records]
GROUP BY [Name];

--
Duane Hookom
MS Access MVP
--

Ssystems said:
Please help with a query grouping project using Access 2003.

Table: (11 records)
Name Loc Approv Action

Jones top
Jones Yes
Jones Go
Smith Stop
Smith Middle
Frank top
Frank No
Frank Jump
Jane Middle
Jane Yes
Jane Stop

The name field is primary and therefore always populated.

I need my query result to look like this (the indent to show the
grouping):
The grouping in on the second field.

LOC Name Approved Action

top
Jones Yes Go
Frank No Jump
middle
Smith Stop
Jane Yes Stop

Can the above be done with a query or at least a flat result that I can
group within the report that looks like:
Jones top Yes Go
Smith Middle Stop
Frank top No Jump
Jane Middle Yes Stop


This has been stumpping me for a couple day now - so any help would be
much
appreciated.

Thanks,
 

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

Back
Top