Re: Counting

From: Gerald Stanley (gcstanley_at_dsl.pipex.com)
Date: 03/31/04


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
>.
>



Relevant Pages

  • Re: Counting
    ... FROM (SELECT DISTINCT [Invoice No], [container Number] FROM ... > I hope that there was a typo in your example as the count ... > Gerald Stanley MCSD ...
    (microsoft.public.access.queries)
  • Re: sichere ellipse (...)
    ... Erzeuge entsprechende Varianten der Funktion, wie Du es hier schon zeigst. ... Das dabei ein Typo passieren kann ist Schicksal aber kein riesiges Problem in meinen Augen. ... Wenn so viele Argumente von einem Typ verwendet werden solltest Du Dir Gedanken machen ob Du nicht einen Container aufbaust und dessen Referenz übergibst. ...
    (microsoft.public.de.vc)
  • Re: add JPanel and JLabel on JButton
    ... >> JButton is a container so you can add components in the same way you ... Was that a typo? ... http://www.AThompson.info/andrew/ personal site ...
    (comp.lang.java.gui)
  • Re: setting up tables
    ... Labour, Products, Customers, Orders, Confirmation, Deposits, Invoice, ... Payments and Container import, what would be the best order to set these up ...
    (microsoft.public.access.tablesdbdesign)
  • Re: Component
    ... The point of that would be to achieve compatibility with the desktop so you ... Container would do whatever you're using it for on a desktop and ... Best regards, ... >> Just do nothing it as without Site property it's pretty much useless, ...
    (microsoft.public.dotnet.framework.compactframework)