> I am trying to determine how I can check on the number of occurences
> of a certain 'identifier', say 'customer code', that are contained in a
> query that I run. If there is only one occurrence then I do not wish to
> output that code.

hi john

instead of putting query results into an array (query results sort of
already are anyway), just issue a query against the query -- this is a cf 5
feature, and it's in the docs

another option is not to bring back single-row results in the first place

so your original query might be

   select Customer, "Date", "Days O/S"
      from yourtable
    where Customer in
       ( select Customer
           from yourtable
        group by Customer
           having count(*) > 1 )

the inner query groups your rows by Customer, and discards any that have
only one row, so the outer query gets detailed rows for only customers with
more than one row

rudy
http://rudy.ca/


-
You are subscribed to the CFUGToronto CFTALK ListSRV.
This message has been posted by: "rudy" <[EMAIL PROTECTED]>
To Unsubscribe, Please Visit and Login to http://www.CFUGToronto.org/
Manager: Kevin Towes ([EMAIL PROTECTED]) http://www.CFUGToronto.org/
This System has been donated by Infopreneur, Inc.
(http://www.infopreneur.net)

Reply via email to