Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Concatenation in a Totals Query 1

Status
Not open for further replies.

teach314

Technical User
Jul 29, 2011
183
CA
hi to all

I have a table like this...
The PK is Type & Rank. SubType is either 1 or 2 (ASC). x holds single-character string values.

Code:
 Type     Rank    SubType      x
=================================
  100      1         1         2
  100      2         1         4
  100      3         2         3
  100      4         2         5
  100      5         2         X
  
  101      1         1         2
  101      2         2         q
  101      3         2         w

  102      1         2         m
  102      2         2         5
  102      3         2         a
  
etc...

I want to GROUP BY Type and SubType. I want the aggregate field to show the CONCATENATED x values in the order shown.
Here's what the output should look like...

Code:
 Type    SubType   SerialNum
=============================
  100      1           24
  100      2           35x

  101      1           2 
  101      2           qw

  102      2           m5a

etc...
[/code[

I can't figure out howto do the concatenation.   Thanks in advance for any help!
 
Consider using the Concatenate function in this forum's FAQs faq701-4233.


Duane
Minnesota
Hook'D on Access
MS Access MVP 2001-2016
 
hey Duane - this is a great resource. Many thanks!
teach314
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top