I am using MYSQL & PHPAdmin
I have a column called dispatchdate which is being stores as VARCHAR(255). It is storing dates though as '12/06/2013' format. (DD/MM/YYYY)
I want to be able to in my PHP page display only the dates for the current month.
Can somebody please help with the following:
1) What query can I use in MYSQL to show only results within the current month? (like a GETDATE? function)
2) Do I need to convert my VARCHAR into DateTime first in my select statement?
3) How do I go about changing the VARCHAR(255) to DATE? I tried in the STRUCTURE option, (Under CHANGE) but after I changed it to DATE i lost all my values and they displayed NULL
Can anyone please help with this?
I am assuming I need to use a CAST function, but i've tried different formats and MYSQL gives me an error.
Would appreciate any help.