Select and count DISTINCT records

niimodinniimodin Member Posts: 142
Hello Experts,
I have a table with keys(Order Date, Order No) hence the Order Date is not unique per record.
How can I count the distinct Order Dates.
Thanks

Comments

  • kapamaroukapamarou Member Posts: 1,152
    Where do you need this?

    If it is on a report you can count using grouping.

    If it is in some piece of code, I would add a record variable for table Date, declare it temporary and do an IF
    tempDateRec.INSERT THEN;
    
    for all my records. After that call
    tempDateRec.COUNT.
  • niimodinniimodin Member Posts: 142
    It is in a report
Sign In or Register to comment.