Re: Desperately need help with a Query



Thanks, Thats what I thought, was hoping that there was an easiest way to do so

Stephane

"PC Data***" wrote:

> You need to create a function that iterates through your records and for
> each Report# builds a comma separated string of all the Serials associated
> with the Report#. The function goes in a standard module and then you enter
> the function in an empty field in your query to give you ListOfSerial.
> Assuming your function is named SerialList, it would look like this in your
> query:
> SerialList(ReportNum)
>
> Note that your query would be a totals query.
>
> --
> PC Data***
> Your Resource For Help With Access, Excel And Word Applications
> resource@xxxxxxxxxxxxxxx
> www.pcdata***.com
>
>
> "Stephane Pelletier" <StephanePelletier@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in
> message news:224C96A5-0567-46E1-8B55-9BE5CCAA011C@xxxxxxxxxxxxxxxx
> > Hi
> >
> > I need to know if it's possible to do one thing and if yes how !!!
> >
> > Here's an example of an output of my DB (DB is Fiction of course,but the
> > question that follow is for real)
> >
> > ID report# Test# Location depth
> > Serial
> > 10951 1 1 CH: 0+100 -900
> >
> > 10952 1 2 CH: 0+110 -900
> > AB-05
> > 10953 1 3 CH: 0+100 -300
> > 10954 1 4 CH: 0+110 -300
> > AB-06
> > 10955 1 5 CH: 0+100 Final
> > AB-07
> > 10956 1 6 CH: 0+110 Final
> > 10957 2 1 xxxxxxxxxx Final
> >
> >
> > Now I would like to have a query that would give me the following output
> >
> > Report count(location) ListOfSerial
> > 1 6 AB-05,AB-06,AB-07
> > 2 1
> >
> > Ok I know that the first two column are easy to have using the GROUP BY
> > clause, my problem is on the third column ... I'm not even sure it's
> > possible
> > to do so but if it's possible to do it ... I'd like very much to have a
> > hint
> > cause i'm clueless for now.
> >
> > IF Any one can help ... Please do so !!!
> >
> > Many Thanks for your help,
> >
> > Stephane Pelletier
>
>
>
.