samona Posted June 5, 2008 Share Posted June 5, 2008 Is there a way to get the previous weekday using a MySql statement? For example, if it is Monday, then the previous weekday would be Friday. Link to comment https://forums.phpfreaks.com/topic/108865-previous-weekday/ Share on other sites More sharing options...
Barand Posted June 5, 2008 Share Posted June 5, 2008 You could use a CASE statement Link to comment https://forums.phpfreaks.com/topic/108865-previous-weekday/#findComment-558515 Share on other sites More sharing options...
fenway Posted June 5, 2008 Share Posted June 5, 2008 It's quite easy if you check DAYOFWEEK() [1..7, starts of Sunday]. Link to comment https://forums.phpfreaks.com/topic/108865-previous-weekday/#findComment-558780 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.