1 Reply Latest reply on Mar 15, 2013 3:57 PM by Dan Bracuk

    Group output on date

    straffenp Level 1

      Hi all,

       

      I have a series of records stored in an Access table, each of them including a date/time.  I am attempting to output my records grouping them on my date/time column, but because each time is unique, I get a separtate group for each record. Is it possible in my CF query to eliminate the time and just pull the date info?  If so, how?  For example, I want all records dated 3/15/2013 to be grouped, instead of 5 different records for 3/15/2013 grouped 5 different ways because of their varying times.

       

      Thank you in advance!

        • 1. Re: Group output on date
          Dan Bracuk Level 5

          When you run your query, add a string constant to the select clause.

           

          select blah, blah, MyDateTimeField, 'update later' GroupField

          from etc

          order by MyDateTimeField

           

          Then loop through your results and use querysetcell to set GroupField to DateFormat(MyDateField, 'mask of your choice').