With raw SQL I habitually do the following:
SELECT * FROM users WHERE MONTH(birthday) = 11 AND DAY(birthday) = 17
.
But these MONTH()
and DAY()
functions does not work with all databases =/
So what is the best way to do this that works with any database supported by Doctrine?