Re: [PHP-DB] Date question

2006-03-17 Thread Gerry Danen
This works perfect, Bastien! Many thanks. Gerry On 3/13/06, Bastien Koert [EMAIL PROTECTED] wrote: select * from table where date_format(date_field, '%Y-%m') = '2006-02' bastien From: Gerry Danen [EMAIL PROTECTED] To: php-db@lists.php.net CC: [EMAIL PROTECTED] Subject: [PHP-DB] Date

RE: [PHP-DB] Date question

2006-03-13 Thread Bastien Koert
select * from table where date_format(date_field, '%Y-%m') = '2006-02' bastien From: Gerry Danen [EMAIL PROTECTED] To: php-db@lists.php.net CC: [EMAIL PROTECTED] Subject: [PHP-DB] Date question Date: Sun, 12 Mar 2006 20:44:13 -0700 While I am rebuilding my crashed laptop (the machine

[PHP-DB] Date question

2006-03-12 Thread Gerry Danen
While I am rebuilding my crashed laptop (the machine that had all my intelligence), I started thinking about a select statement I need. I have log info in a table and want to extract it on a monthly basis. The date field is in -mm-dd format. What's a good way to select those dates that match

Re: [PHP-DB] Date question

2006-03-12 Thread LJ Regalado
For example, you have table `logs` with `datelog` field and you want to select dates that match 2006-02. You can try this select statement: SELECT * FROM `logs` WHERE MONTH(datelog)='02' and YEAR(datelog)='2006' Hope that helps. LJ Regalado

Re: [PHP-DB] Date question

2006-03-12 Thread Chris
Gerry Danen wrote: While I am rebuilding my crashed laptop (the machine that had all my intelligence), I started thinking about a select statement I need. I have log info in a table and want to extract it on a monthly basis. The date field is in -mm-dd format. What's a good way to select

[PHP-DB] Date Question

2004-10-27 Thread Bomgardner, Mark A
I am having trouble converting a date from mm/dd/ to -mm-dd on a user form. I know there was post about this, but I keep getting an error message when I try to search the archives. I have looked at the manual, but I am not finding what I am looking for. Mark A. Bomgardner

RE: [PHP-DB] Date Question

2004-10-27 Thread Bastien Koert
How are you trying to convert the date? bastien From: Bomgardner, Mark A [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: [PHP-DB] Date Question Date: Wed, 27 Oct 2004 11:17:16 -0500 I am having trouble converting a date from mm/dd/ to -mm-dd on a user form. I know there was post about

Re: [PHP-DB] Date Question

2004-10-27 Thread John Holmes
Bomgardner, Mark A wrote: I am having trouble converting a date from mm/dd/ to -mm-dd on a user form. I know there was post about this, but I keep getting an error message when I try to search the archives. I have looked at the manual, but I am not finding what I am looking for. echo

[PHP-DB] Date Question

2003-02-19 Thread Chris Payne
Hi there everyone, I have the following 2 dates (FOr example): 19-02-2003 21-02-2003 How can I easily find out how many nights there are between the 2 dates? For example, the above would be 2 nights as the 21st would be the checkout date. I have the use the format about as that is how the

[PHP-DB] Date Question

2002-11-29 Thread Chris Payne
Hi there everyone, I've never really used the date functions beyond getting it to store the current date in a db. I have a dilema in that I need to get all the days in the current month and all the days in the next month (whatever the next month is depends on the current month the script was

Re: [PHP-DB] Date Question

2002-04-03 Thread root
PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, April 03, 2002 5:26 PM Subject: [PHP-DB] Date Question Hi all, If I have a feild called 'date' and the type is date when a form is submitted isn't it suppose to automatically enter the date or do I need to somehow enter it through the form