Find the COUNT(next month Between next month +2DAYS) for the created date in table(including Year wise Dec ,Jan like)
How to do this using mysql query Query need for both datatype date and datetime
If you only want the MONTH, then use SELECT MONTH('2011-03-28' + INTERVAL 1 MONTH)
Works the same for DATE and DATETIME (replace the actual date I quoted with your own SQL and column name). For more info you can refer to http://dev.mysql.com/doc/refman/5.1/en/datetime.html
SELECT COUNT(whatever)
FROM
yourTable
WHERE
yourDateColumn BETWEEN NOW()+INTERVAL 1 MONTH AND NOW()+INTERVAL 1 MONTH + INTERVAL 2 DAYS
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With