I have a web task for counting some data inside DB. I must count this data daily, weekly, and monthly.
For weekly, I am still confused to decide which MySQL syntax I should use for this case.
There are two suggestions to resolve this problem: using DAY()
or WEEK()
.
I want this syntax is not limited by a confusing thing. As should declare the first of the month and end of month or start in Sunday or Monday, etc. I want it every time cans for use (but focuses at weekly).
Which is the one that I can use? DAY() or WEEK()?