Forum Discussion

KatherineOakey's avatar
KatherineOakey
Qrew Member
4 years ago

How to 'convert' Date/Time to Date to use DayofWeek?

I have a table with records, each of which has a field containing a Date/Time, say RegisterDate.

I want to be able to generate a report/chart that can sum the number of RegisterDates that are on Monday or Tuesday.  I don't care about the month or time... expecting a report with no more than 7 rows with a sum next to each day of the week.

I have tried adding a field that is a formula Date in the table. The syntax correct but when I just list the records with both the formula Date field and the Date/Time field, I see the Date/Time that contains the day of the week (which I'd really rather display other than a number but I'll deal with this later).  The column with the formula Date field displays nothing.

The formula I'm using is

DayOfWeek(ToDate([Related Event - Event Date & Time]))

Where Related Event - Event Date & Time  was selected via the Edit formula using a text field and then the Choose fields & functions dropdown before the formula box.

And it tells me it's expecting a date, not a number.  Do  need to add another function to convert the number to text?

------------------------------
Katherine Oakey
------------------------------

1 Reply

  • Whoops - never mind - fixed the formula from Date to Text and now I get the numbers of the weeks...

    Yay.

    Now I want to display/chart as the actual day but am hoping that isn't too hard to figure out :)

    ------------------------------
    Katherine Oakey
    ------------------------------