Re: MySQL SELECT question

From: Date: Thu, 16 Nov 2000 03:24:42 +0000
Subject: Re: MySQL SELECT question
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-25588@lists.php.net to get a copy of this message
this might be of some help http://www.mysql.com/documentation/mysql/commented/ you can do a search on time or date functions.... there are lots more.. eg : dayofmonth().. or .. month()..... etc... one disadvantage of inserting a unix timestamp instead of a yyyy-mm-dd format is that there is a limitation.. but it 's far from now.... a yyyddmm format gives more flexibility.... but then again... a unix timestamp can be much more precise and date arithmetic can be done easily in some cases... [john] Ben Wiechman wrote: > Since I couldn't seem to uncover a decent example... > > Can I use multiple where clauses in a select statement? > i.e. > > SELECT FROM table WHERE this = 'that'AND thishere = 'thatthere' > > And another question... > > I have a date field in my table > > Is it possible to match, for example, only the month? > > i.e. > > SELECT * FROM table WHERE FORMAT_DATE( DATE, %m ) = '<value from 1-12 here>' > > Thanks > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#25588) next »