MySQL Forums
Forum List  »  Newbie

Pick Month from Date
Posted by: mudasir mirza
Date: December 31, 2009 12:37AM

I made a script few days back which saves DATE/TIME in following PHP format
$dte=date("l F d, Y, h:i A");
$query = "insert into abc (name, date) values ('$name', '$dte')";
mysql_query ($query);

which saves datetime similar to
"Friday December 25, 2009, 11:58 PM"

Now i am learning to make a script to show monthly data present against a particular name in the database.
I would like to know how can i get only month from the above code

The field date is of datatype varchar.

which SQL query can get records of the whole month of december for a particular name.


Looking forward for a quick and positive reply.



Kind Regards.

Options: ReplyQuote


Subject
Written By
Posted
Pick Month from Date
December 31, 2009 12:37AM
December 31, 2009 01:28AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.