>-Original Message-
>From: Johan De Meersman [mailto:vegiv...@tuxera.be]
>Sent: Monday, June 06, 2011 12:57 PM
>To: Jerry Schwartz
>Cc: mysql@lists.mysql.com
>Subject: Re: Timestamp value
>
>
>I may be mistaken, but isn't UTC pretty much GMT if you don'
I may be mistaken, but isn't UTC pretty much GMT if you don't want subsecond
precision? Set your server's timezone to GMT and you should get what you want.
- Original Message -
> From: "Jerry Schwartz"
> To: mysql@lists.mysql.com
> Sent: Monday, 6 June, 2011 5:10:22 PM
> Subject: Timest
Here is my test.
Any way can retrieve the metadata.
On Fri, May 9, 2008 at 10:45 PM, Martijn Tonies <[EMAIL PROTECTED]>
wrote:
>
>
> > SHOW CREATE TABLE ...
>
> Yes, I thought so :-(
>
>
> From a coding point of view, this requires parsing...
>
> Why isn't there anything in "show full columns".
>
> SHOW CREATE TABLE ...
Yes, I thought so :-(
>From a coding point of view, this requires parsing...
Why isn't there anything in "show full columns".
Martijn Tonies
Database Workbench - tool for InterBase, Firebird, MySQL, NexusDB, Oracle &
MS SQL Server
Upscene Productions
http://www.upsce
SHOW CREATE TABLE ...
Martijn Tonies wrote:
Hi,
How does one know if ON UPDATE CURRENT_TIMESTAMP was specified when
creating a column? How do I retrieve this bit of info from the metadata
queries?
(also MySQL 4.1)
Martijn Tonies
Database Workbench - tool for InterBase, Firebird, MySQL, NexusDB
If you decide to use the trigger here is the syntax
http://dev.mysql.com/doc/refman/5.0/en/triggers.html
And that table structure looks ok to me
As far as the backup goes just dump the mysql database, which you should be
doing anyway to backup users etc
Olaf
On 9/4/07 3:59 PM, "Hiep Nguyen"
so, if trigger is used then
create table temp (
id int not null primary key auto_increment,
data varchar(100),
inserted timestamp,
lastupdated timestamp)
is good enough, right? trigger will use now() function to set inserted &
lastupdated.
any thought on backup & restore tables & tringgers??
Just do this...
create table temp (
id int not null primary key auto_increment,
data varchar(100),
inserted timestamp default 0,
lastupdated default CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP
);
And just use
Insert into temp (inserted ) values (NOW());
You're only inserting once, so ju
There is nothing terribly wrong with the approach documented in
'http://sql-info.de/mysql/examples/CREATE-TABLE-examples.html' but, as
you no doubt have read, it does mean that you have to make sure that
every insert statement is specifically designed to set the *second*
timestamp field to now() an
is it possible to do without trigger?
i google and found this link:
http://sql-info.de/mysql/examples/CREATE-TABLE-examples.html
but when i tried to combine two examples into one CREATE statement and it
didn't work.
any idea?
is there a way to create this table that accomplishes these two go
Agreed...
Also for consistency's sake
On 9/4/07 3:15 PM, "Michael Dykman" <[EMAIL PROTECTED]> wrote:
> Triggers are a fine idea, but I would use a trigger for both cases..
> no point putting that level of housekeeping on the application when
> you can set rules in the database and more or less f
Triggers are a fine idea, but I would use a trigger for both cases..
no point putting that level of housekeeping on the application when
you can set rules in the database and more or less forget about it.
- michael
On 9/4/07, Olaf Stein <[EMAIL PROTECTED]> wrote:
> I would use a trigger (at lea
I would use a trigger (at least for the update)
The first insert should work with now() and you can leave lastupdateted
empty
Olaf
On 9/4/07 3:01 PM, "Hiep Nguyen" <[EMAIL PROTECTED]> wrote:
> Hi list,
>
> i tried to create a table with inserted & lastupdated timestamp fields:
>
> creat
> I need to create a "commands" table. A program will periodically check
on this table whether
> there's a pending command for it to execute or not. Whatever the reason,
this program might read a command but not acknowledge it's
> execution.
> Other program will check out whether the command t
10/04/2006 11:51
Para: <[EMAIL PROTECTED]>,
Asunto: Re: timestamp & not null
Hi,
> I created a table and, into it, a timestamp field:
> ... EXPIRES TIMESTAMP NOT NULL, ...
>
> When I issue the command "describe" it shows the field "expires" allows
nul
Hi,
> I created a table and, into it, a timestamp field:
> ... EXPIRES TIMESTAMP NOT NULL, ...
>
> When I issue the command "describe" it shows the field "expires" allows
nulls and defaults to CURRENT_TIMESTAMP. Also, each time I update
> a field other than "expires" in this table, "expires" gets
- Original Message -
From: "Ferindo Middleton Jr" <[EMAIL PROTECTED]>
To: "Ferindo Middleton Jr" <[EMAIL PROTECTED]>
Cc: "Hank" <[EMAIL PROTECTED]>;
Sent: Friday, March 31, 2006 7:30 PM
Subject: Re: TIMESTAMP field not automatically upda
Ferindo Middleton Jr wrote:
Hank wrote:
Are the other fields in the update statement actually changing the
data? I don't know for sure, but if the data on disk is the same as
the update statement, mysql won't actually update the record, and
therefore might not update the last_updated field also.
Hank wrote:
Are the other fields in the update statement actually changing the
data? I don't know for sure, but if the data on disk is the same as
the update statement, mysql won't actually update the record, and
therefore might not update the last_updated field also. Just a
thought.
Yes, I
Hank wrote:
Are the other fields in the update statement actually changing the
data? I don't know for sure, but if the data on disk is the same as
the update statement, mysql won't actually update the record, and
therefore might not update the last_updated field also. Just a
thought.
It's true
Are the other fields in the update statement actually changing the
data? I don't know for sure, but if the data on disk is the same as
the update statement, mysql won't actually update the record, and
therefore might not update the last_updated field also. Just a
thought.
--
MySQL General Mailing
jonathan wrote:
are you having two timestamp fields in a table (ie a created and a
last_updated)?
-j
On Mar 30, 2006, at 5:17 PM, Ferindo Middleton Jr wrote:
I think I've seen this complaint posted before but I ignored but now
I realize that in some of my db tables' last_updated field the val
are you having two timestamp fields in a table (ie a created and a
last_updated)?
-j
On Mar 30, 2006, at 5:17 PM, Ferindo Middleton Jr wrote:
I think I've seen this complaint posted before but I ignored but
now I realize that in some of my db tables' last_updated field the
value is automat
> I think I've seen this complaint posted before but I ignored but now I
> realize that in some of my db tables' last_updated field the value is
> automatically updating on UPDATEs to records while in other tables the
> last_updated fields for some strange reason aren't automatically updating.
>
>
e-
> From: Ricardas.S [mailto:[EMAIL PROTECTED]
> Sent: 21 March 2006 14:31
> To: [EMAIL PROTECTED]
> Subject: Re: Timestamp problem in mysql5.0.18
>
>
> Yes, I think you are right, it should be the main reason of
> insert failure.
> Thank you for good idea.
>
> Ricka
&
Further, your reporting will skew the data -- let's say once a day you
want to know the last time that row was read. Well, the first day,
you'll get accurate numbers. The second day, though, you'll end up
seeing that each row was read at latest the day before, because you
read it searching for th
"fbsd_user" <[EMAIL PROTECTED]> wrote on 03/13/2006 01:10:17 PM:
> In my mysql 4.4 table definition the default attributes are (ON
> UPDATE CURRENT_TIMESTAMP). Reading the manual my understanding is
> this is saying that the auto timestamp update feature is active. The
> manual does not say what t
On 3/2/06, rtroiana <[EMAIL PROTECTED]> wrote:
> Thanks to all of you for replying. I'm using DATETIME instead of TIMESTAMP
> now. Although I still haven't find the answer for my second question.
>
>
>
> > > I used to use
> > > "CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP" as default value for my
lumn. Is there a way to assign default value to a DateTime
> > column, since I couldn't find that in the documentation?
_
From: Rhino [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 02, 2006 3:50 PM
To: [EMAIL PROTECTED]
Cc: mysql@lists.mysql.com; rtroiana
Subje
PROTECTED]
To: Rhino
Cc: mysql@lists.mysql.com ; rtroiana
Sent: Thursday, March 02, 2006 1:42
PM
Subject: Re: TimeStamp issue
In fact, no time values in
MySQL are fractional (yet). All times are stored to the nearest second
regardless of which date-time-like storage type you
In fact, no time values in MySQL are fractional (yet). All times are
stored to the nearest second regardless of which date-time-like storage
type you use. They way Rhino phrased his answer, it sounded as though
TIMSTAMP would save fractional seconds. It doesn't. He is spot on about
needing a se
If you need a broader range of dates, you could use DATETIME instead of
TIMESTAMP: DATETIME can handle the range '1000-01-01 00:00:00' through
'-12-31 23:59:59'. The only big difference is that DATETIME does not
store the fractional part of the seconds, e.g.
milliseconds/microseconds/nanons
rtroiana wrote:
Hi All,
I have recently noticed in the MySQL 5.0 documentation in section 11.3.1.
The DATETIME, DATE, and TIMESTAMP Types, it's mentioned that
"TIMESTAMP values cannot be earlier than 1970 or later than 2037. This means
that a date such as '1968-01-01', while legal as a D
pedro mpa wrote:
Greetings!
I am building a website using MySQL 5.0.18 and PHP 5.1.2.
When I try to insert in a table a timestamp value from php's mktime() I get
the following error:
1292: Incorrect datetime value: '1139776424' for column 'access_date' at row
1
The sql for the table is:
CREATE
Hello.
Have you checked if the timestamp column is set with CURRENT_TIMESTAMP as
the default value?
If it doesnt, you can try this:
ALTER TABLE tbl MODIFY column TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE
CURRENT_TIMESTAMP;
And mysql will fill the column with current timestamp
Ryan,
Try to use this date functions.
* DATE_ADD(date,INTERVAL expr type) , DATE_SUB(date,INTERVAL expr type)
These functions perform date arithmetic. date is a DATETIME or DATE value
specifying the starting date. expr is an expression specifying the interval
value to be added or subtracte
Hi Ryan,
On Wed, 2005-11-16 at 19:16 +0800, Ryan Escarez wrote:
> is it possible to get the the given (unix)timestamp in milliseconds
> since the epoch?
No, it is not possible. However this is on the roadmap.
This is also reported as Bug #8523:
http://bugs.mysql.com/bug.php?id=8523
Regards,
Pe
[EMAIL PROTECTED] wrote:
Hi,
I have a row in mysql database called time and is just a simple timestamp
column
When I echo it out
echo $row['time'];
echo $row['content'];
I get the following
2005-08-30 13:50.05 "this is the text content"
Now I am not worried about the time but I would like
> 2005-08-30 13:50.05 "this is the text content"
> (i) sort the returned rows in order (latest first)
http://dev.mysql.com/doc/mysql/en/sorting-rows.html
> (ii) be able to extract the individual parts of the date and display them in
> UK format (ddmm)
http://www.php.net/manual/en/function.
If you run the select "SELECT NOW() + 1*RAND();" a few times, you'll
see that not all values are valid timestamps, e.g.:
mysql> SELECT NOW() + 1*RAND();
+--+
| NOW() + 1*RAND() |
+--+
| 20050713112881 |
+--+
1 row in set
Hello.
There were several bugs related to timestamp
at 4.0.22 and later. Does the problem remains
on 4.1.12 (4.0.24)?
manasvini nandakumar <[EMAIL PROTECTED]> wrote:
> Hi all,
> I have a very strange problem with mysql-4.0.22
> running on a big endian processor platform.When the
> tim
> http://dev.mysql.com/doc/mysql/en/timestamp-4-1.html
>
> > Absolutely brilliant document *g* ...
> >
> > So now, it makes a difference if it's the first TIMESTAMP column,
> > if it's running in MaxDB mode, if it has a defaulf of NULL (which will
> > be silently changed), if it has no default, a
On 6/9/05, Martijn Tonies wrote:
http://dev.mysql.com/doc/mysql/en/timestamp-4-1.html
> Absolutely brilliant document *g* ...
>
> So now, it makes a difference if it's the first TIMESTAMP column,
> if it's running in MaxDB mode, if it has a defaulf of NULL (which will
> be silently changed), if
Thank you Michael for your very thoughtful reply. I know that it takes
time and effort to answer at the level you did.
Michael Stassen Michael.Stassen-at-verizon.net |Lists| wrote:
> You seem to have a fundamental misunderstanding of the TIMESTAMP type.
> No timezone or DST information is stored
Peter Valdemar Mørch wrote:
From the lack of responses I take it that nobody disagrees that the
handling of the timestamp type is fundamentally broken in every version
of MySQL.
Silence does not necessarily indicate assent. You asked a complicated
question (when the U.S. list members were on h
From the lack of responses I take it that nobody disagrees that the
handling of the timestamp type is fundamentally broken in every version
of MySQL.
I'll go ahead and file several bugs, and start changing our code to
avoid the timestamp type altogther. I'm quite surprised!
Peter
Peter Valdema
At 17:34 +0200 4/7/04, Pierre Didelon wrote:
Hi,
I am using mysql and I need to store timestamp.
In input I got something like yyy-dddThh:mm:ss,
ddd beeing the day of the year!
I would like to make the minimun transformation before
loading data in database, so I would like to enter the timestamp
wi
> I want to change the column choose to ENUM('y', 'n', 'weekly') without
> changing the timestamp. How can I do that?
I tried ALTER TABLE as usual, and it didn't affect the timestamp. Sorry
I didn't try this from the beginning :)
--Batara
--
MySQL General Mailing List
For list archives: http:
Scott Plumlee wrote:
[EMAIL PROTECTED] wrote:
Hi,
(Please note: NEWBIE WARNING, below questions might sound stupid, but
feel free to flame.) ;-)
I have a table "tbl_users" with a field "dat_an_time" which is a
timestamp(14).
In that I have values such as:
2004022215
20040227042018
20040223
Ryan A wrote:
/**
Somewhat new myself but I believe you can do something like SELECT
(whatever you need) FROM tbl_users WHERE (UNIX_TIMESTAMP(now()) -
($days_last*24*60*60)) < UNIX_TIMESTAMP(dat_and_tim).
I will add the the PHP Cookbook and the MySQL Cookbook are godsends and
that's where
[EMAIL PROTECTED] wrote:
Hi,
(Please note: NEWBIE WARNING, below questions might sound stupid, but feel
free to flame.) ;-)
I have a table "tbl_users" with a field "dat_an_time" which is a
timestamp(14).
In that I have values such as:
2004022215
20040227042018
20040223015329
etc
I have search
My first question would be, "Why is this column is TIMESTAMP?". It
seems to me that if its purpose is to store the subscription start date,
it should be of type DATE. Usually, you use a TIMESTAMP column to
automatically keep track of the last updated time for a row.
Either way (DATE or TIMEST
2 (of many) solutions here:
Create the column as a datetime instead and set it with NOW() when you first
insert the data.
In your update query, set the hr_con column to the current value.
(If you set the value explicitly it will not be updated with the automatic
timestamp value.)
read this for
Hi Leandro,
It is absolutly correct. Please read in doc about timestamp data type
http://www.mysql.com/doc/en/DATETIME.html
The TIMESTAMP column type provides a type that you can use to automatically
mark INSERT or UPDATE operations with the current date and time. If you
Mike Blezien <[EMAIL PROTECTED]> wrote:
>
> what is the best way to convert a TIMESTAMP value to a value
> similar to a DATETIME value ??
>
If you mean TIMESTAMP column type, you can just change column type with ALTER TABLE
statement.
--
For technical support contracts, goto https://order.
i've used FROM_UNIXTIME with success. you can also supply a format.
http://www.mysql.com/doc/en/Date_and_time_functions.html
hth
jeff
mazur <[EMAIL PROTECTED]> wrote:
> Anyone know if there is a way to defeat the new format for the
> timestamp that appears in 4.1 alpha?
>
> I upgraded a MySQL install on a development box that holds a copy of
> our production data. I quickly saw that the timestamp format was
> changed from:
>
>
yes, it automatically inserts the time.
>From the manual:
6.2.2.2 The DATETIME, DATE, and TIMESTAMP Types: (
http://www.mysql.com/doc/en/DATETIME.html )
"The TIMESTAMP column type provides a type that you can use to automatically
mark INSERT or UPDATE operations with the current date and time. If
On Thursday 06 March 2003 13:40, wrote:
> I'm currently building a database and am using a timestamp(14) column for
> keeping track of when an entry was added to it. Is there an easy way to
> remove records that are more than 180 days old inside a MySQL query
> instead of going through and removi
* [EMAIL PROTECTED]
> I'm currently building a database and am using a timestamp(14) column for
> keeping track of when an entry was added to it.
Beware that this column also will be updated when you update _any_ column in
the row...
http://www.mysql.com/doc/en/DATETIME.html >
> Is there an easy
At 12:17 PM +0100 1/31/03, Marco Deppe wrote:
Hi,
I was already questioning my sanity, but the problem below is
reproduceable:
This is how my table looks:
mysql> describe T_ORDH;
--+--+-+++
Field |Type |Null |Key |D
Hi.
On Fri 2003-01-31 at 12:17:42 +0100, [EMAIL PROTECTED] wrote:
>
> I was already questioning my sanity, but the problem below is
> reproduceable:
>
[...]
> If I do
> mysql> update T_ORDH set STATUS=2 where PK_ID=26272;
> ERSTELL_DATUM is set to the current date. I know that a timestamp
> take
Since that is exactly how the manual describes it, it must be a feature.
If you have more than one timestamp, they will all get set on an insert,
but only the first will be changed on an update.
Marco Deppe wrote:
Hi,
I was already questioning my sanity, but the problem below is
reproduceable:
At 12:17 +0100 1/31/03, Marco Deppe wrote:
Hi,
I was already questioning my sanity,
Don't. Reading the manual is more helpful. :-)
but the problem below is
reproduceable:
This is how my table looks:
mysql> describe T_ORDH;
--+--+-+++
Marco,
> mysql> update T_ORDH set STATUS=2 where PK_ID=26272;
> ERSTELL_DATUM is set to the current date. I know that a timestamp
> takes the current time, if set it to NULL, but since I'm not touching
> it, it shouldn't change, should it?
>
> A quick workaround is
> mysql> update T_ORDH set STATU
Read the section in the manual about timestamps, this is expected behavior,
it is how it is supposed to work.
http://www.mysql.com/doc/en/DATETIME.html
The TIMESTAMP column type provides a type that you can use to automatically
mark INSERT or UPDATE operations with the current date and time. If yo
Hi,
It is a feature, the first TIMESTAMP field is automatically
updated each time you update the record. Check the manual
for details:
http://www.mysql.com/doc/en/DATETIME.html
If you want mysql to automatically set it at creation time only,
your workaround is OK.
You can also convert ERSTELL_DA
Timestamp columns update automatically.
http://www.mysql.com/doc/en/DATETIME.html
Peter
<^_^>
> -Original Message-
> From: Marco Deppe [mailto:[EMAIL PROTECTED]]
> Sent: Friday, January 31, 2003 6:18 AM
> To: [EMAIL PROTECTED]
> Subject: TIMESTAMP field is updated unintentionally
>
>
Thanks,
Ed
On Mon, 6 Jan 2003, Roger Baklund wrote:
> * [EMAIL PROTECTED]
> > I have a table of records using timestamp(14) as a field and need to
> > remove any records that are 60 days past the timestamp. I've looked at the
> > manual and can't find anything relating on doing this. What qu
* [EMAIL PROTECTED]
> I have a table of records using timestamp(14) as a field and need to
> remove any records that are 60 days past the timestamp. I've looked at the
> manual and can't find anything relating on doing this. What query would I
> need to run on the database?
To remove records, use
Date/Time is such a tricky thing. I think that's we migrated toward the
simplest solution in the first place.
For days/weeks/months, I think the math cited below works pretty well. That
is, if we're not talking about calendar months. As soon as we need to query
based on calendar things, we tend
On Monday 23 December 2002 12:41, Akash wrote:
> I want to store NULLS or '0' in a column which is of type
> TimeStamp.
> According to MySQL implementation, if I give the default value of the
> column during table creation as NULL, it will store the current time in the
> timestamp colu
]]
> Sent: Monday, December 23, 2002 9:16 AM
> To: [EMAIL PROTECTED]
> Cc: Akash
> Subject: Re: TimeStamp in MySQL reqd NULL
>
> On 23 Dec 2002, at 16:11, Akash wrote:
>
> > According to MySQL implementation, if I give the default value of the
>
On 23 Dec 2002, at 16:11, Akash wrote:
> According to MySQL implementation, if I give the default value of the column
> during table creation as NULL, it will store the current time in the
> timestamp column. I do not want this "current time" to be stored in the
> timestamp column. I want it to be
At 19:32 -0600 11/25/02, Ronald Petty wrote:
I am trying to get my TIMESTAMPE field to auto update (use the current time
for inserts). However it keeps going to all 00, I read the
documentation and it says that is because it is getting an invalid input.
However it also states if you put n
At 11:41 + 11/7/02, Nikolas Galanis wrote:
Ok, here we are, in much detail. There is a table called
translations and another one called poems. Their structure is given
in the end. The query (given by a php script by the way) is:
select poems.poem_id, language, translation_title,made_by_id f
Nikolas Galanis wrote:
and with this I intend to retrieve the 10 latest additions of
translations. However, when running the script, I noticed that always,
on the top of the results was the translation link I had clicked last.
And this happens all the time. Now that I think of it again, the
c
Ok, here we are, in much detail. There is a table called translations
and another one called poems. Their structure is given in the end. The
query (given by a php script by the way) is:
select poems.poem_id, language, translation_title,made_by_id from
poems,translations where poems.poem_id=tran
At 2:09 +0200 11/7/02, Galanis Nikolas wrote:
Yes, that is exactly what happens. It is updated with a simple select
statement. It is a select from a table which contains only one timestamp
column and the order by is made by this timstamp column. And every time
the value if the timestamp is updated
Yes, that is exactly what happens. It is updated with a simple select
statement. It is a select from a table which contains only one timestamp
column and the order by is made by this timstamp column. And every time
the value if the timestamp is updated.
On Wed, 6 Nov 2002, Paul DuBois wrote:
> A
At 23:47 + 11/6/02, Nikolas Galanis wrote:
Hello
I have a column of type timestamp(14) and I thought it would not be
updated on a query with simple select statements, though it does! I
read in the manual that it
shouldn't, what could be wrong? Thanks.
You're saying that performing a SELECT
Hello
I have a column of type timestamp(14) and I thought it would not be
updated on a query with simple select statements, though it does! I read in the manual that it
shouldn't, what could be wrong? Thanks.
-
Bef
Mikhail,
- Original Message -
From: "Mikhail Entaltsev" <[EMAIL PROTECTED]>
To: "Heikki Tuuri" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Monday, October 21, 2002 1:11 PM
Subject: Timestamp field in the InnoDB table
> Hi,
>
> I have found one unclear place for me regarding to the tim
Mikhail,
- Original Message -
From: "Mikhail Entaltsev" <[EMAIL PROTECTED]>
To: "Heikki Tuuri" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Monday, October 21, 2002 2:34 PM
Subject: Re: Timestamp field in the InnoDB table
> Heikki,
>
> t
in the documentation.
Thank you.
Best regards,
Mikhail.
- Original Message -
From: "Heikki Tuuri" <[EMAIL PROTECTED]>
To: "Mikhail Entaltsev" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Monday, October 21, 2002 1:20 PM
Subject: Re: Timest
;[EMAIL PROTECTED]>; "Mikhail Entaltsev"
<[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Monday, October 21, 2002 3:08 PM
Subject: RE: Timestamp field in the InnoDB table
Hi,
This is almost my requirement.I have to update the exact timestamps(most
critical for me) and I
isn't that the month changing?
it's changing from october to january...??
Alan
> -Original Message-
> From: Jay X [mailto:sparqz50@;hotmail.com]
> Sent: Monday, 21 October 2002 12:20
> To: [EMAIL PROTECTED]
> Subject: timestamp bug increments by one day
>
>
> Hi There,
>
> Just recientl
At 16:49 +0530 9/17/02, Prafulla Girgaonkar wrote:
>Mysql Version::
>
>Server version 3.23.47-nt
>Protocol version10
>Connection . via named pipe
>UNIX socket MySQL
>
>OS::
>Windows NT 4.0 Workstation
>
>
>Hello
>Following is the description of the problem
Prafulla,
Tuesday, September 17, 2002, 2:12:58 PM, you wrote:
PG> Following is the description of the problem being faced.
PG> Problem:
PG> The first timestamp column in a table is set to current date-time value as soon as
we update one or more columns in the table.
It's a normal behaviour of
Prafulla,
please check documentation http://www.mysql.com/doc/en/DATETIME.html
"...
The TIMESTAMP column type provides a type that you can use to automatically
mark INSERT or UPDATE operations with the current date and time. If you have
multiple TIMESTAMP columns, only the first one is updated au
whow, this list is so very powerfull .. just give me your address and I'll
send you the beer .. what kind of it would you like?
-Oorspronkelijk bericht-
Van: Luc Foisy [mailto:[EMAIL PROTECTED]]
Verzonden: June 14, 2002 16:04
Aan: Wouter van Vliet; MYSQL-List (E-mail)
Onderwer
This is exactly what timestamp columns are supposed to do - see
http://www.mysql.com/doc/D/A/DATETIME.html
The first timestamp column in the table will be automatically updated
upon insert/update. Your choices are:
(1) Change to datetime type. Then, on insert, insert the current date
Wouter,
Friday, June 14, 2002, 4:53:20 PM, you wrote:
WvV> I'm having a slight problem with the timestamp column format. When I alter a
WvV> table and, add a column of type timestamp all records get the current
WvV> timestamp, that's ok. When i insert a new row, all records get the current
WvV> t
The first timestamp in any table is automatically updated by mysql every time you
modify that record. It is the modify timestamp
If you wish to use the timestamp in your table, you should create two timestamps at
least and use the second one
Modstamp timestamp
Usable timestamp
See here http:/
r,
Thursday, May 30, 2002, 12:35:58 PM, you wrote:
r> in a timestamp field, do I have to provide the values?
r> eg
r> create table ryan(t_imestamp timestamp(8), name varchar(30));
r> how do I insert? do I have to specify the value? if so how do I get the
r> value to specify it?
r> The man
On 27 May 2002, at 22:32, [EMAIL PROTECTED] wrote:
> mysql> SELECT dd,count(*) FROM test GROUP BY dd;
> +--+--+
> | dd | count(*) |
> +--+--+
> | 20020527 |1 |
> | 20020527 |1 |
> | 20020527 |1 |
> | 20020527 |1 |
> +--
sitnikov,
Monday, May 27, 2002, 10:32:07 PM, you wrote:
s> Description:
s> Problem with timestamp(8) and GROUP BY
s> How-To-Repeat:
mysql>> CREATE TABLE test (
s> -> id int auto_increment,
s> -> dd timestamp(8),
s> -> data int,
s> -> PRIMARY KEY (id)
s> -> );
s> Quer
try timestamp(14) instead.
[EMAIL PROTECTED] wrote:
>Description:
> Problem with timestamp(8) and GROUP BY
>
>How-To-Repeat:
>
>mysql> CREATE TABLE test (
>-> id int auto_increment,
>-> dd timestamp(8),
>-> data int,
>-> PRIMARY KEY (id)
>-> );
>Query OK, 0 rows affecte
The is the proper, documented functionality of the timestamp field. An
exerpt from http://www.mysql.com/doc/D/A/DATETIME.html is below:
The TIMESTAMP column type provides a type that you can use to automatically
mark INSERT or UPDATE operations with the current date and time. If you have
multipl
At 3:22 PM -0400 5/20/02, Alex Pilson wrote:
>Is it possible to alter or modify a timestamp field to a different date?
Doh. I found the answer...
The answer is yes.
--
<--->
Alex Pilson
FlagShip Interactive, Inc.
[EMAIL P
1 - 100 of 132 matches
Mail list logo