Determine DayOfWeek from a SQLDate

Hi. Is there a way to determine the day of the week when given the date in SQL format?

For example, if given 2017-04-26 or 2014-08-20, what is the day of the week?

I have a table of orders where the date is in SQLDate, and I’d now like to utilize a chart showing the number of orders for each day of the week, but I never saved to the table the DayOfWeek to make this easy on myself

Create a new Date, assign the SQLDate value and then check the DayOfWeek property.

Yikes that was easy. I was making that out to be tougher than it needed to be. Thanks Paul!

You didn’t say what SQL you were using, but here’s an article on how to get the results in SQLite. sqlite return as day of week

select _id, busnum, cast (strftime('%w', servdate) as integer) as servdayofweek from tb1 where ...