[SOLVED] mysql/date

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
MrKnight
Forum Newbie
Posts: 22
Joined: Fri Jan 28, 2005 8:54 am
Location: Another Planet

[SOLVED] mysql/date

Post by MrKnight »

hello,
in my sql i would like to select all the entries that added on 5th of any month, can be? if so, how?
(dates were stored such as '0000-00-00')
if this is not possiple, i am open to ideas...
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

Code: Select all

... WHERE EXTRACT( DAY FROM `date_field`) = '5'
something like that....
MrKnight
Forum Newbie
Posts: 22
Joined: Fri Jan 28, 2005 8:54 am
Location: Another Planet

Post by MrKnight »

thank you so much, it worked... :)
erm thanks once more :D
Post Reply