[AccessD] Union Query quick question

O'Connor, Patricia (OTDA) Patricia.O'Connor at otda.state.ny.us
Wed Dec 21 15:42:35 CST 2005


THANK YOU THANK YOU THANK YOU

I knew I had done this before but could not remember to use the max was
just tried the group by

Have a nice day
Patti

**************************************************
* Patricia O'Connor
* Associate Computer Programmer Analyst
* OTDA - BDMA
* (W) mailto:Patricia.O'Connor at otda.state.ny.us
* (w) mailto:aa1160 at otda.state.ny.us
**************************************************
 

> 
--------------------------------------------------------
This e-mail, including any attachments, may be confidential, privileged or otherwise legally protected. It is intended only for the addressee. If you received this e-mail in error or from someone who was not authorized to send it to you, do not disseminate, copy or otherwise use this e-mail or its attachments.  Please notify the sender immediately by reply e-mail and delete the e-mail from your system. 


-----Original Message-----

> From: accessd-bounces at databaseadvisors.com 
> [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of 
> Stuart McLachlan
> Sent: Wednesday, December 21, 2005 03:56 PM
> To: Access Developers discussion and problem solving
> Subject: Re: [AccessD] Union Query quick question
> 
> On 21 Dec 2005 at 15:32, O'Connor, Patricia (OTDA) wrote:
> 
> > Right now I for each CASENO Carea I can get 1 to 3 records. Each 
> > record for a Caseno, Carea would have a particular grouping 
> filled and the others null
> >      C1234,01,a1,a2,a3,  ,  ,  ,  ,  ,  ,
> >      C1234,01,  ,  ,  ,b1,b2,b3,
> >      C1234,01,  ,  ,  ,  ,  ,  ,c1,c2,c3,
> > 
> > I would like to have the output look like
> >      C1234,01,a1,a2,a3,b1,b2,b3,c1,c2,c3,
> > 
> Try
> 
> Select Distinct CaseNo, CArea,
> max(a1),max(a2),max(a3),
> max(b1),max(b2),max(b3),
> max(c1),max(c2),max(c3)
> 
> >From table1
> 
> Group By CaseNo,CArea
>  --
> Stuart
> 
> 
> -- 
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>



More information about the AccessD mailing list