Re: date format problem

2004-05-03 Thread Egor Egorov
the date column in my mysql tables to accept a date in this format or do i really have to go through every sql statement and parse the date and rebuild it to be -mm-dd? thanks so much. If you want to store values in the DATE columns you shoul convert all data to the -mm-dd format

date format problem

2004-04-30 Thread Matt Tucker
Hi, I'm moving a JavaServlet app over from Tomcat on Win2K with a MS SQL 7 DB to Tomcat on Red Hat Linux with mySQL. Of course, there's about a hundred queries that use dates and of course, they're all in the format mm-dd-. is there a way to format the date column in my mysql tables

error importing date

2004-04-20 Thread Fajar Priyanto
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all, I encounter this error when importing database from one mysql server into another: the date imported is wrong. The type is timestamp. In the dump file, the date is : 0404121921, but when imported, it becomes: 0004041219. Could anybody pls

RE: error importing date

2004-04-20 Thread Victor Pendleton
How are you exporting/importing the data? -Original Message- From: Fajar Priyanto To: [EMAIL PROTECTED] Sent: 4/20/04 3:51 AM Subject: error importing date -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all, I encounter this error when importing database from one mysql server

Re: error importing date

2004-04-20 Thread Fajar Priyanto
of every timestamp. On Tuesday 20 April 2004 08:49 pm, Victor Pendleton wrote: How are you exporting/importing the data? -Original Message- From: Fajar Priyanto To: [EMAIL PROTECTED] Sent: 4/20/04 3:51 AM Subject: error importing date Hi all, I encounter this error when importing

Re: error importing date

2004-04-20 Thread Fajar Priyanto
the same for both tables? What is that column type? TIMESTAMP(14)? -Original Message- From: Fajar Priyanto To: Victor Pendleton; '[EMAIL PROTECTED] ' Sent: 4/20/04 9:16 AM Subject: Re: error importing date Hi Victor, thanks for responding. I really need help here. I export/import

Re: error importing date

2004-04-20 Thread Egor Egorov
Fajar Priyanto [EMAIL PROTECTED] wrote: Hi all, I encounter this error when importing database from one mysql server into=20 another: the date imported is wrong. The type is timestamp. In the dump file, the date is : 0404121921, but when imported, it becomes:= 0004041219. Could anybody

RE: error importing date

2004-04-20 Thread Victor Pendleton
I am not certain but it appears that you date values are shifting to the right. Can you create a test case using timestamp(14) and see if the error occurs? -Original Message- From: Fajar Priyanto To: Victor Pendleton; ''[EMAIL PROTECTED] ' ' Sent: 4/20/04 10:19 AM Subject: Re: error

RE: error importing date

2004-04-20 Thread Victor Pendleton
Are you exporting/importing the DDL as well? Is the column type the same for both tables? What is that column type? TIMESTAMP(14)? -Original Message- From: Fajar Priyanto To: Victor Pendleton; '[EMAIL PROTECTED] ' Sent: 4/20/04 9:16 AM Subject: Re: error importing date -BEGIN PGP

Re: Change the date format.

2004-04-11 Thread Egor Egorov
David Carlos Brunstein [EMAIL PROTECTED] wrote: Hi Egor. Thanks for your answer. I'm relatively new to MySQL. Isn't any way -like an environment variable or configuration file setting or something like that- to change the date format at the MySQL side, not at client side ? No. You can

Re: Change the date format.

2004-04-10 Thread Egor Egorov
David Carlos Brunstein [EMAIL PROTECTED] wrote: By these days I'm facing a system DB migration to MySQL (the last production version) and I have the followin problem. All the SELECTs sentences are all over the application, and for date/datetime filters are using the dd/mm/ format

RE: Change the date format.

2004-04-10 Thread David Carlos Brunstein
Hi Egor. Thanks for your answer. I'm relatively new to MySQL. Isn't any way -like an environment variable or configuration file setting or something like that- to change the date format at the MySQL side, not at client side ? Regards, David. == David Carlos Brunstein

Change the date format.

2004-04-09 Thread David Carlos Brunstein
Hi, I'm new to the list. By these days I'm facing a system DB migration to MySQL (the last production version) and I have the followin problem. All the SELECTs sentences are all over the application, and for date/datetime filters are using the dd/mm/ format in the WHERE clause. Is the same

Record Change Date

2004-04-01 Thread Jeff Cook
Is there any way to see what date a record was changed on? I am building a database of mostly imported CSV files. The files would be imported on the day they were created and would not have a date field in them. May hope would be to have a field in the database that would show the date

Re: Record Change Date

2004-04-01 Thread Victor Pendleton
Can you add a timestamp field in your table? This field will be updated upon insertion and updates. On Thu, 01 Apr 2004, Jeff Cook wrote: Is there any way to see what date a record was changed on? I am building a database of mostly imported CSV files. The files would be imported on the day

Tricky date formatting issue

2004-03-31 Thread Scott Haneda
I can not seem to wrap my head around the string functions I will need to work this issue out... MySql 4 I have a column 'tmp_date' that was imported from a messy data set, trying to clean it up. The date is in the format of: m/d/yy and mm/dd/yy Somehow, I need to update a timestamp(14) column

Re: Tricky date formatting issue

2004-03-31 Thread Jigal van Hemert
I have a column 'tmp_date' that was imported from a messy data set, trying to clean it up. The date is in the format of: m/d/yy and mm/dd/yy Somehow, I need to update a timestamp(14) column based on the tmp_date as the input. Nice challenge ;-) For MySQL 4.0.x: SET @d='01/02/03'; SELECT

Date Problem

2004-03-09 Thread Eric Scuccimarra
We have a table with a Date Time field and we need to update only the date portion of that field. We have table a with field Foo with value '2004-01-01 12:15:00' and a date '2004-03-01' and we need to change the date portion of Foo to the date and leave the time part alone. So Foo would

Re: Date Problem

2004-03-09 Thread Richard Davey
Hello Eric, Tuesday, March 9, 2004, 11:46:23 PM, you wrote: ES We have a table with a Date Time field and we need to update only the date ES portion of that field. ES We have table a with field Foo with value '2004-01-01 12:15:00' and a date ES '2004-03-01' and we need to change the date

Re: Date Problem

2004-03-09 Thread Peter Burden
Richard Davey wrote: Hello Eric, Tuesday, March 9, 2004, 11:46:23 PM, you wrote: ES We have a table with a Date Time field and we need to update only the date ES portion of that field. ES We have table a with field Foo with value '2004-01-01 12:15:00' and a date ES '2004-03-01' and we need

Re[2]: Date Problem

2004-03-09 Thread Richard Davey
Hello Peter, Wednesday, March 10, 2004, 12:16:51 AM, you wrote: PB But that is adding two days, the original query was to add two PB months, so presumably it should be INTERVAL 2 MONTH - but beware PB that MySQL does some It should, sorry, I'm too used to the UK date format (even though I know

Re: query date ranges

2004-03-07 Thread Michael Stassen
Kevin Waterson wrote: I have been trying this is several ways, currently I have a mess MySQL 4.1.1 PHP as the interface I have a table of with a date range called seasons. in it I have two date ranges and an amount to be charged for each day in the range 2004-01-01 00:00:00 2004-06-01 00:00

Re: query date ranges - step 2

2004-03-06 Thread Kevin Waterson
This one time, at band camp, Kevin Waterson [EMAIL PROTECTED] wrote: seasonDateFrom seasonDateTo seasonRateWeekly 2004-06-02 00:00:002004-10-31 00:00:00 42.86 2004-01-01 00:00:002004-06-01 00:00:00 34.29 When I take a booking I have yet another range

query date ranges

2004-03-05 Thread Kevin Waterson
I have been trying this is several ways, currently I have a mess MySQL 4.1.1 PHP as the interface I have a table of with a date range called seasons. in it I have two date ranges and an amount to be charged for each day in the range 2004-01-01 00:00:00 2004-06-01 00:00:0044 2004-06-02

Why Doesn;t this Date Query Work?

2004-02-24 Thread Scott Bailey
. $sql = 'SELECT Username, Count( Username ) FROM MainDetails, Usernames WHERE MainDetails.UserID = Usernames.UserID and Date Between \'$Date1\' and \'$Date2\' GROUP BY Username'; The strange thing is if I replace the $Date2 variable with a date manually it works -. i.e. $sql = 'SELECT Username

Re: Why Doesn;t this Date Query Work?

2004-02-24 Thread Jigal van Hemert
$sql = 'SELECT Username, Count( Username ) FROM MainDetails, Usernames WHERE MainDetails.UserID = Usernames.UserID and Date Between \'$Date1\' and \'$Date2\' GROUP BY Username'; The strange thing is if I replace the $Date2 variable with a date manually it works -. i.e. Not a MySQL issue

Re: Why Doesn;t this Date Query Work?

2004-02-24 Thread Scott Bailey
Fantastic! This was indeed the problem and has solved it. Many thanks! On Tue, 24 Feb 2004 13:14:51 +0100, Jigal van Hemert wrote: $sql = 'SELECT Username, Count( Username ) FROM MainDetails, Usernames WHERE MainDetails.UserID = Usernames.UserID and Date Between \'$Date1\' and \'$Date2

date column question

2004-02-11 Thread rmck
to use for my date column start? Thanks upfront Rob -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Re: date column question

2004-02-11 Thread Roger Baklund
or recommended datatype to use for my date column start? Try DATETIME: URL: http://www.mysql.com/doc/en/DATETIME.html -- Roger -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]

Create a date value 7 days from now

2004-02-07 Thread Matthew Stuart
I am trying to get MySQL to automatically create a date seven days from the date a new record is created. The new records will be inserted through an ASP, VBScript website. I have managed to get this to work in MS Access by typing in to its default field in the database Now()+7. As you would

Re: Create a date value 7 days from now

2004-02-07 Thread Roger Baklund
* Matthew Stuart I am trying to get MySQL to automatically create a date seven days from the date a new record is created. The new records will be inserted through an ASP, VBScript website. I have managed to get this to work in MS Access by typing in to its default field in the database Now

Re: Create a date value 7 days from now

2004-02-07 Thread Matthew Stuart
a date seven days from the date a new record is created. The new records will be inserted through an ASP, VBScript website. I have managed to get this to work in MS Access by typing in to its default field in the database Now()+7. As you would expect, it gives me a date 7 days from now. I have

Re: Create a date value 7 days from now

2004-02-07 Thread Roger Baklund
* Matthew Stuart I assume the INSERT statement you have suggested goes on the webpage that has the form from which the new record will be created, Is that correct? Yes. -- Roger -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:

[Q] setting DATE field with default NOW value?

2004-02-05 Thread Riaan Oberholzer
In a table definition, how do I get a date field to be assigned as DEFAULT the current date? I tried: dateField DATE DEFAULT CURDATE() but that gives me syntax errors Help? __ Do you Yahoo!? Yahoo! Finance: Get your refund fast by filing online. http

Re: [Q] setting DATE field with default NOW value?

2004-02-05 Thread Martijn Tonies
Hi, In a table definition, how do I get a date field to be assigned as DEFAULT the current date? I tried: dateField DATE DEFAULT CURDATE() but that gives me syntax errors Help? According to the documentation for the DEFAULT value clause, value can only be a real value

Re: [Q] setting DATE field with default NOW value?

2004-02-05 Thread KKoTY
you can use TIMESTAMP data type, which have default NOW() - Original Message - From: Riaan Oberholzer [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, February 05, 2004 12:38 PM Subject: [Q] setting DATE field with default NOW value? In a table definition, how do I get a date

Re: [Q] setting DATE field with default NOW value?

2004-02-05 Thread Martijn Tonies
you can use TIMESTAMP data type, which have default NOW() Not exactly. 1) TIMESTAMP also updates when you update the row, unless you set the column value to its current value. 2) not in maxdb mode. http://www.mysql.com/doc/en/DATETIME.html In a table definition, how do I get a date

Re: [Q] setting DATE field with default NOW value?

2004-02-05 Thread Brent Baisley
If you update the row with NULL for the TIMESTAMP field it will enter the current date and time. On Feb 5, 2004, at 7:18 AM, Martijn Tonies wrote: you can use TIMESTAMP data type, which have default NOW() Not exactly. 1) TIMESTAMP also updates when you update the row, unless you set

Re: Subtracting date fields

2004-01-30 Thread Aftab Jahan Subedar
try SELECT id,(TO_DAYS(firstdate)- TO_DAYS(postdate)) AS diff FROM calendar well you have to put the bigger date on the lhs. Kenneth Letendre wrote: Hello, I'm trying to get the difference (in days) between dates stored in two date fields. My query: SELECT id,(firstdate- postdate) AS diff

yearweek() result back to date format?

2004-01-26 Thread Trevor Smith
How can I use the output string of the yearweek() function (for example, 200346 below): mysql select dayname(2003-11-12), yearweek(2003-11-12); +---++ | dayname(2003-11-12) | yearweek(2003-11-12) |

Re: yearweek() result back to date format?

2004-01-26 Thread KKoTY
date of first Monday (Monday because i'm Czech) of first week in a year. There is a lot of ways to number weeks, see WEEK() function . I think it's impossible to get this date (the date of first day of first week) just in query, maybe you can write your own function ;)) But if you are using something

DATE Manipulation

2004-01-22 Thread Andy Prasetya
Hello, I'm a newbie in MySQL. I have a table that contains column 'startdate [date]' and 'enddate [date]'. Somehow, I have to execute SQL that search any entry that corresponds to the current year and current month, e.g.: SELECT * FROM mytable WHERE fieldx = '123' AND (startdate LIKE '2004-01

Re: DATE Manipulation

2004-01-22 Thread Chris W
Andy Prasetya wrote: Hello, I'm a newbie in MySQL. I have a table that contains column 'startdate [date]' and 'enddate [date]'. Somehow, I have to execute SQL that search any entry that corresponds to the current year and current month, e.g.: SELECT * FROM mytable WHERE fieldx = '123

Re: DATE Manipulation

2004-01-22 Thread Vinay
this could help http://www.mysql.com/doc/en/Date_and_time_functions.html V!nay Chris W wrote: Andy Prasetya wrote: Hello, I'm a newbie in MySQL. I have a table that contains column 'startdate [date]' and 'enddate [date]'. Somehow, I have to execute SQL that search any entry

Validate date

2004-01-17 Thread Hassan Shaikh
Quote from MySQL documentation ... MySQL allows you to store some wrong date values into DATE and DATETIME columns (like 2000-02-31 or 2000-02-00). The idea is that it's not the SQL server job to validate date. If MySQL can store a date and retrieve exactly the same date, then MySQL will store

Re: Selecting by date

2004-01-16 Thread Lowell Allen
I have created a sql statement that enables me to select all entries in to MySQL that are dated today, I am trying to do the same for all items that are now one day old and also two days old etc I am doing this: SELECT * FROM table WHERE category = 3 AND show = 1 AND date = NOW()-1 I

RE: Selecting by date

2004-01-16 Thread Mike Johnson
WHERE category = 3 AND show = 1 AND date = NOW()-1 I have it working for todays records, it filters out any that don't match todays date or NOW(), but it still returns the same records for NOW()-1, or NOW()-2. I have tried DATE() but this gives me an error. What is the correct syntax

Selecting by date

2004-01-15 Thread Matthew Stuart
I have created a sql statement that enables me to select all entries in to MySQL that are dated today, I am trying to do the same for all items that are now one day old and also two days old etc I am doing this: SELECT * FROM table WHERE category = 3 AND show = 1 AND date = NOW()-1 I have

Date query question

2004-01-10 Thread Eric Anderson
; And what I'm looking to be able to do is to be able to sum up totals based on date, whether it be today, yesterday, last week, last month, etc. I'm currently using 4.0.14, so I don't have access to certain functions (like date()), otherwise I'd be able to do something like this: SELECT count

Re: Subtracting date fields

2004-01-09 Thread Ryan Yagatich
On Sat, 2004-01-31 at 14:57, Kenneth Letendre wrote: Hello, I'm trying to get the difference (in days) between dates stored in two date fields. My query: SELECT id,(firstdate- postdate) AS diff FROM calendar This works fine if the two dates are in the same month

Re: Default DATE field values

2004-01-04 Thread Chris Nolan
it to its current value, if you weren't aware of that. Matt - Original Message - From: Chris Nolan Sent: Saturday, January 03, 2004 10:34 AM Subject: Default DATE field values Hi all, Upon reading the funky manual, I have discovered the following things: 1. TIMESTAMP

Default DATE field values

2004-01-03 Thread Chris Nolan
Hi all, Upon reading the funky manual, I have discovered the following things: 1. TIMESTAMP fields can be set so that their default value is NOW(). 2. DATE and TIMESTAMP fields are related. Given the two above facts, is there a way to set DATE columns so the default value is NOW()? My playing

Re: Default DATE field values

2004-01-03 Thread Matt W
, if you weren't aware of that. Matt - Original Message - From: Chris Nolan Sent: Saturday, January 03, 2004 10:34 AM Subject: Default DATE field values Hi all, Upon reading the funky manual, I have discovered the following things: 1. TIMESTAMP fields can be set so that their default

Re: Subtracting date fields

2004-01-03 Thread robert_rowe
Just try to access the databases with the permissions that you had previously set up. If you can then it worked okay. If you can't then use grant to set your permissions up again. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:

Re: Subtracting date fields

2004-01-01 Thread Matt W
Dan, DATEDIFF() only works in MySQL 4.1.1+. RTFM! ;-) Matt - Original Message - From: [EMAIL PROTECTED] Sent: Wednesday, December 31, 2003 2:10 PM Subject: RE: Subtracting date fields Kenneth, try SELECT id, DATEDIFF(firstdate, postdate) AS diff FROM calendar RTFM

RE: Subtracting date fields

2004-01-01 Thread stairwaymail-mysql
-Original Message- From: Matt W [mailto:[EMAIL PROTECTED] Sent: Thursday, January 01, 2004 4:42 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: Subtracting date fields Dan, DATEDIFF() only works in MySQL 4.1.1+. RTFM! ;-) Matt - Original Message - From: [EMAIL PROTECTED] Sent

Re: Subtracting date fields

2004-01-01 Thread Matt W
to be portable to different systems, I suggest using things compatible with 3.23. And when you have to use something that's not, handle it in your code. Matt - Original Message - From: Bob Terrell [EMAIL PROTECTED] Sent: Thursday, January 01, 2004 5:35 PM Subject: Re: Subtracting date fields

Subtracting date fields

2003-12-31 Thread Kenneth Letendre
Hello, I'm trying to get the difference (in days) between dates stored in two date fields. My query: SELECT id,(firstdate- postdate) AS diff FROM calendar This works fine if the two dates are in the same month, but not otherwise. MySQL appears to be treating the two dates as base-10

Subtracting date fields

2003-12-31 Thread Kenneth Letendre
Hello, I'm trying to get the difference (in days) between dates stored in two date fields. My query: SELECT id,(firstdate- postdate) AS diff FROM calendar This works fine if the two dates are in the same month, but not otherwise. MySQL appears to be treating the two dates as base-10

RE: Subtracting date fields

2003-12-31 Thread stairwaymail-mysql
Kenneth, try SELECT id, DATEDIFF(firstdate, postdate) AS diff FROM calendar RTFM! hope that helps, dan -Original Message- From: Kenneth Letendre [mailto:[EMAIL PROTECTED] Sent: Saturday, January 31, 2004 1:51 PM To: [EMAIL PROTECTED] Subject: Subtracting date fields Hello, I'm

Re: Subtracting date fields

2003-12-31 Thread Scott Haneda
on 01/31/2004 11:57 AM, Kenneth Letendre at [EMAIL PROTECTED] wrote: Hello, I'm trying to get the difference (in days) between dates stored in two date fields. My query: SELECT id,(firstdate- postdate) AS diff FROM calendar This works fine if the two dates are in the same month

date conversion

2003-12-21 Thread landon kelsey
found out that 4.0 has a date format converter thanks for the Perl actually I wrote a Qt/C++ program to convert the date _ Worried about inbox overload? Get MSN Extra Storage now! http://join.msn.com/?PAGE=features/es -- MySQL

date and not null

2003-12-21 Thread landon kelsey
why did this date work: insert into log_book values ('08-12-1973','C150','N5787G',1,1.8); date looks good in table...has been rearranged to std format and this didn't insert into salesreps values (109,'Mary Jones',31,11,'Sales Rep','10-12-1989',106,30.00,392725.00); date is -00-00

RE: date and not null

2003-12-21 Thread Andrew Braithwaite
| | In your mysql desc log_book; Cheers, A -Original Message- From: landon kelsey [mailto:[EMAIL PROTECTED] Sent: Sunday 21 December 2003 23:12 To: [EMAIL PROTECTED] Subject: date and not null why did this date work: insert into log_book values ('08-12-1973','C150','N5787G',1,1.8); date

Oracle date

2003-12-20 Thread landon kelsey
sql from Oracle insert into log_book values (TO_DATE('08/12/1973','MM/dd/'),'C150','N5787G',1,1.8); would like insert into log_book values (STR_TO_DATE('08-12-1973','%m-%d-%Y'),'C150','N5787G',1,1.8); according to the manual, STR_TO_DATE is not until 4.0...I have 3.23.52 hate to write a

Re: Oracle date

2003-12-20 Thread beacker
The kind of processing you desired is easily accomplisches with the following perl program: #!/usr/bin/perl while (STDIN) { if (/TO_DATE/) { s/TO_DATE/STR_TO_DATE/; s/(..)\/(..)\/()/$1-$2-$3/; s/MM\/dd\//%m-%d-%Y/; } print $_; } [EMAIL PROTECTED] cat

RE: Comparing date fields (Delphi programmers take note)

2003-12-18 Thread Noamn
like queries with date parameters (one must pass the date as a literal) 2. the date format has to be changed to that of mySQL. 3. if one uses a table alias (p in my case), one is not allowed to use the full table name - projects.closeddate causes an error, but p.closeddate is ok. So I wrote a small

Re: Comparing date fields (Delphi programmers take note)

2003-12-18 Thread Martijn Tonies
is that 1. mySQL doesn't like queries with date parameters (one must pass the date as a literal) Hmmm... I do make use of parameters, but I noticed MySQL doesn't provide me with the right datatype (like Firebird or InterBase do). So I'm passing everything as a string to the parameter. :-/ 2

Re: Getting Records where date is LESS THAN today, AND...

2003-12-16 Thread Martijn Tonies
Hi Richard, Okay, that sounds good and all, but how does that help me, since the date is chosen from the javascript calander in this format: mm/dd/ So then, when I'm selecting a date of at least todays value, or less in the database how would I do it, since it's in mm/dd/? I

Comparing date fields

2003-12-16 Thread Noamn
I'm in the process of converting an application from Paradox to mySQL which is why I have these syntax questions. mySQL doesn't like a query with this syntax: select p.name, from projects p, ... where p.closeddate = :fd and p.closeddate = :td ... where fd (from date) and td (till date

RE: Comparing date fields

2003-12-16 Thread Jay Blanchard
[snip] I'm in the process of converting an application from Paradox to mySQL which is why I have these syntax questions. mySQL doesn't like a query with this syntax: select p.name, from projects p, ... where p.closeddate = :fd and p.closeddate = :td ... where fd (from date) and td (till

RE: Comparing date fields

2003-12-16 Thread Noamn
- From: Jay Blanchard [mailto:[EMAIL PROTECTED] Sent: Tuesday, December 16, 2003 4:04 PM To: Noamn; [EMAIL PROTECTED] Subject: RE: Comparing date fields [snip] I'm in the process of converting an application from Paradox to mySQL which is why I have these syntax questions. mySQL doesn't like

RE: Comparing date fields

2003-12-16 Thread Jay Blanchard
[snip] I started with between, but when this didn't work, I switched to the comparison operators. mysql select projects.name from projects - where projects.closeddate between :fd and :td; ERROR 1064: You have an error in your SQL syntax near ':fd and :td' at line 2 [/snip] What are those

Re[2]: Comparing date fields

2003-12-16 Thread DeBug
mysql select projects.name from projects JB - where projects.closeddate between :fd and :td; JB ERROR 1064: You have an error in your SQL syntax near ':fd and :td' at JB line JB 2 JB What are those colons? He probably uses Delphi or C++Builder to connect to mysql via TQuery component. TQuery

Re: Re[2]: Comparing date fields

2003-12-16 Thread Martijn Tonies
mysql select projects.name from projects JB - where projects.closeddate between :fd and :td; JB ERROR 1064: You have an error in your SQL syntax near ':fd and :td' at JB line JB 2 JB What are those colons? He probably uses Delphi or C++Builder to connect to mysql via TQuery

RE: Re[2]: Comparing date fields

2003-12-16 Thread Noamn
To: [EMAIL PROTECTED] Subject: Re: Re[2]: Comparing date fields mysql select projects.name from projects JB - where projects.closeddate between :fd and :td; JB ERROR 1064: You have an error in your SQL syntax near ':fd and :td' at JB line JB 2 JB What are those colons? He probably uses

Re: Getting Records where date is LESS THAN today, AND...

2003-12-15 Thread Martijn Tonies
Is there a BETTER way to do this? Yes, store a DATE instead of seperate day/month/year values. With regards, Martijn Tonies Database Workbench - developer tool for InterBase, Firebird, MySQL MS SQL Server. Upscene Productions http://www.upscene.com -- MySQL General Mailing List For list

Re: Getting Records where date is LESS THAN today, AND...

2003-12-15 Thread Richard
Okay, that sounds good and all, but how does that help me, since the date is chosen from the javascript calander in this format: mm/dd/ So then, when I'm selecting a date of at least todays value, or less in the database how would I do it, since it's in mm/dd/? Thanks, Richard

Problems using date with MySQL 4.1.0 - Alpha

2003-12-14 Thread Lenny Sorey
I am currently using MySQL 4.1 Win2K version along ODBC 3.5.1 Driver I am having trouble using the following LOAD DATA INFILE to import a txt, comma delimited file into to a Mysql Table. Actually the only problem is the date field loading into mysql 4.1. I have defined the field as a date

Getting Records where date is LESS THAN today, AND...

2003-12-14 Thread Richard
I am Creating a newsletter site for my employer, which will allow him to just add the newsletter and choose which day to mail it. a cron job runs everynight and mails out a notice that the newsletter is ready, along with the link. I am having a problem getting the date to match up... I have

Re: Problems using date with MySQL 4.1.0 - Alpha

2003-12-14 Thread Paul DuBois
At 18:10 -0600 12/14/03, Lenny Sorey wrote: I am currently using MySQL 4.1 Win2K version along ODBC 3.5.1 Driver I am having trouble using the following LOAD DATA INFILE to import a txt, comma delimited file into to a Mysql Table. Actually the only problem is the date field loading into mysql

Re: Getting Records where date is LESS THAN today, AND...

2003-12-14 Thread Richard
] To: [EMAIL PROTECTED] Sent: Sunday, December 14, 2003 7:54 PM Subject: Getting Records where date is LESS THAN today, AND... I am Creating a newsletter site for my employer, which will allow him to just add the newsletter and choose which day to mail it. a cron job runs everynight and mails out a notice

Date query problem

2003-12-06 Thread Hseyin DEMRA
Hi,This query is give an error like below;There is a column that name and description are date in Table that also include database.in the table,there are some date like that:2003-12-01,2003-11-16,2003-12-01,2003-12-03,2003-11-19. when i run this query,if i query between 2003-12-01 and 2003

Re: Mysql Date column type

2003-12-03 Thread Nitin
no problems that i see. - Original Message - From: p shah [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, December 03, 2003 12:23 PM Subject: Mysql Date column type Hi, I have one question regarding date column type in MYSQL. Can I use the column type for date

Re: Mysql Date column type

2003-12-03 Thread p shah
Hi, But will the search be any faster using Integer or BigInt column type compared to using Date or DateTime columnd type. Regards, --- Nitin [EMAIL PROTECTED] wrote: no problems that i see. - Original Message - From: p shah [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent

Finding most recent date only

2003-12-03 Thread Alec Smith
| | ProdID | | .| | | | .| -- (I have replaced a bunch of other fields with for briefity) What I need to be able to do is get a list of all products not having a transaction since a certain date, but am

Re: Mysql Date column type

2003-12-03 Thread Skippy
On Tue, 2 Dec 2003 22:53:47 -0800 (PST) p shah [EMAIL PROTECTED] wrote: What are the pros and cons for using Integer column type for the date? Please reply at the earliest. Well there are *some* drawbacks but I dunno if they apply to you. For instance, using PHP, when I do a select

Re: Finding most recent date only

2003-12-03 Thread Roger Baklund
date, but am not having much luck. Anyone out there willing to offer save my day? What about something like this: SELECT P.* FROM Products P LEFT JOIN TransDetails TD ON TD.ProdID = P.ProdID LEFT JOIN Transactions T ON T.TransID = TD.TransID AND T.TransDate '$SelectedDate

Date data type issue

2003-12-02 Thread tjkuhn
Having a problem with a Date data type. Here's the query: SELECT distinct date_format(auditdate, %Y%M ) as listUrl, date_format( auditdate, %Y%m ) as blank FROM quality_history WHERE auditdate Now() ORDER BY listUrl desc LIMIT 6 auditdate is a DATE datatype When I run

Re: Date data type issue

2003-12-02 Thread Nitin
now() gives current date and time. use current_date() instead. hope it helps Nitin - Original Message - From: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, December 02, 2003 9:32 PM Subject: Date data type issue Having a problem with a Date data type. Here's the query

Mysql Date column type

2003-12-02 Thread p shah
Hi, I have one question regarding date column type in MYSQL. Can I use the column type for date as Integer instead of DateTime or Date to store the date as mmddhhmmss or mmdd? As I know MYSQL accepts this format. But I am not too sure about the column type. What are the pros and cons

Re: Problem with query comparing to a DATE on Linux OpenOffice

2003-11-11 Thread Marc
, ...) that also has a database interface. You can check it out at www.openoffice.org -Marc Marc [EMAIL PROTECTED] wrote:I'm using OpenOffice 1.1.0 as a front-end to MySQL 4.0.14 on Gentoo Linux and can't compare a field to CURDATE(). The error is, The field cannot be compared with a date

Problem with query comparing to a DATE on Linux OpenOffice

2003-11-10 Thread Marc
I'm using OpenOffice 1.1.0 as a front-end to MySQL 4.0.14 on Gentoo Linux and can't compare a field to CURDATE(). The error is, The field cannot be compared with a date. The column is formatted as a DATE, and I can perform the compare fine using mysql. I realize this is probably related only

Re: Problem with query comparing to a DATE on Linux OpenOffice

2003-11-10 Thread Alaios
what a front-end is? And what OO1.1.0 provides? Marc [EMAIL PROTECTED] wrote:I'm using OpenOffice 1.1.0 as a front-end to MySQL 4.0.14 on Gentoo Linux and can't compare a field to CURDATE(). The error is, The field cannot be compared with a date. The column is formatted as a DATE, and I can

Unusual date storage requirement

2003-10-27 Thread sean peters
Hi all, I have run into a date storage problem that i don't like. A am storing historic house sales, and some of the old data i have received only contains the month and year, but not the date of the sale. Of course we want to store this information, but a DATE column won't quite do the job

RE: Unusual date storage requirement

2003-10-27 Thread John Jolet
what about forcing the date to the first of whatever month the sale was in? if it's got a valid date, put that, otherwise, put the first. -Original Message- From: sean peters [mailto:[EMAIL PROTECTED] Sent: Monday, October 27, 2003 4:33 PM To: [EMAIL PROTECTED] Subject: Unusual date

Re: Unusual date storage requirement

2003-10-27 Thread sean peters
Sorry, i wasn't completely clear. Well, thats actually what i am going to do. A date column won't take anything but a valid date (sort of - feb. 30 is valid). But i still need to know whether the day of month is meaningful or not, for various search / display purposes. My users will raise

Re: Unusual date storage requirement

2003-10-27 Thread Jesse Sheidlower
On Mon, Oct 27, 2003 at 05:32:34PM -0500, sean peters wrote: Hi all, I have run into a date storage problem that i don't like. A am storing historic house sales, and some of the old data i have received only contains the month and year, but not the date of the sale. Of course we want

Re: Unusual date storage requirement

2003-10-27 Thread bluejack
On Mon, 27 Oct 2003 17:58:38 -0500, sean peters [EMAIL PROTECTED] wrote: Well, thats actually what i am going to do. A date column won't take anything but a valid date (sort of - feb. 30 is valid). But i still need to know whether the day of month is meaningful or not, for various search

Re: Unusual date storage requirement

2003-10-27 Thread Paul DuBois
At 5:32 PM -0500 10/27/03, sean peters wrote: Hi all, I have run into a date storage problem that i don't like. A am storing historic house sales, and some of the old data i have received only contains the month and year, but not the date of the sale. Of course we want to store this information

<    3   4   5   6   7   8   9   10   11   12   >