Re: Counting
From: Gerald Stanley (gcstanley_at_dsl.pipex.com)
Date: 03/31/04
- Next message: Brenda glover: "Re: Using input parameter query for creating charts"
- Previous message: anonymous_at_discussions.microsoft.com: "Re: select in the midle of a criteria with iif..."
- In reply to: Karen: "Counting"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 31 Mar 2004 01:50:52 -0800
Try something like
SELECT [Invoice No] , [Container Number],
Count([Reference]) As [Container Count]
FROM [Your Table]
GROUP BY [Invoice No] , [Container Number]
I hope that there was a typo in your example as the count
for GSTU5823584 should be 3.
Hope This Helps
Gerald Stanley MCSD
>-----Original Message-----
>I have a table like this:
>
>Invoice No Container Number Reference
>03-12-767 MSKU1234567 HO02367
>03-12-767 MSKU1234567 TY03592
>03-12-767 GSTU5823584 OD5912
>03-12-767 GSTU5823584 GR5692
>03-12-767 GSTU5823584 IT1593
>
>How do I get a query with these outcome
>Invoice No Container Number Container Count
>03-12-767 MSKU1234567 2
>03-12-767 GSTU5823584 2
>
>Best Regards,
>Karen
>.
>
- Next message: Brenda glover: "Re: Using input parameter query for creating charts"
- Previous message: anonymous_at_discussions.microsoft.com: "Re: select in the midle of a criteria with iif..."
- In reply to: Karen: "Counting"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|