You should post your query. This sounds like it can be done in your query.
Re your example.
Row  Customer                Date                   Days O/S
1    ABC                       Jan 1                   0
2    ABC                       Jan 8                   7
3    DEF                       Jan 1                   0
4    GHI                        Jan 2                   0
5    GHI                        Jan 3                   1
6    GHI                        Jan 17                 14

Do you need to display only row 1 and 4 or rows 1,2,4,5,6?
if the first you could do a select that counts the customer occurence and
if GT 1 display
if the second you could do a sum on days o/s grouped by customer and if its
days o/s  = 0 reject the record.
Anyway I'm not 100% sure of the goal

-steve



                                                                                       
                                  
                    "John Spencer"                                                     
                                  
                    <John.Spencer@ene.        To:     [EMAIL PROTECTED]           
                                  
                    gov.on.ca>                cc:                                      
                                  
                    Sent by:                  Subject:     [CFTALKTor] Query within a 
query?                             
                    owner-cfug@cfugtor                                                 
                                  
                    onto.org                                                           
                                  
                                                                                       
                                  
                                                                                       
                                  
                    07/16/02 02:15 PM                                                  
                                  
                    Please respond to                                                  
                                  
                    CFTALK                                                             
                                  
                                                                                       
                                  
                                                                                       
                                  




Hello Folks:

I am new to CF so please bear with me if you will.

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. I do not know if there will only be one though until the 'code'
changes, since I am doing some calculations on data contained in the record
and then deciding if I would like to output it or not.

At present I have stored everything in an array. I would now like to buzz
through this array and build another, storing the count for each 'code'
used.

Customer                Date                   Days O/S
ABC                       Jan 1                   0
ABC                       Jan 8                   7
DEF                       Jan 1                   0
GHI                        Jan 2                   0
GHI                        Jan 3                   1
GHI                        Jan 17                 14

In this example, I need to show the '0'  records for ABC and GHI but not
the one for DEF so a simple 'if days = 0' will not work. I need to know how
many records have been processed for each customer.

Does this make any sense? I can then read the 2nd array and if the record
count.

Any ideas?

Thanks for your time.

John.

-
You are subscribed to the CFUGToronto CFTALK ListSRV.
This message has been posted by: "John Spencer"
<[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)






-
You are subscribed to the CFUGToronto CFTALK ListSRV.
This message has been posted by: [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