473,503 Members | 5,004 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

timestamp default value

I am using:

mysql Ver 12.22 Distrib 4.0.18, for sun-solaris2.9 (sparc)

And I do this:

mysql> create table test (a timestamp default null, b timestamp default null);
Query OK, 0 rows affected (0.03 sec)

mysql> desc test;
+-------+---------------+------+-----+----------------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------+---------------+------+-----+----------------+-------+
| a | timestamp(14) | YES | | NULL | |
| b | timestamp(14) | YES | | 00000000000000 | |
+-------+---------------+------+-----+----------------+-------+
2 rows in set (0.00 sec)

Can anyone tell my why the default value for column 'b' is not NULL as well?

Thanks, Matthew
Jul 20 '05 #1
0 1582

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
3263
by: My Deja | last post by:
what is the syntax for specifying the default values for timestamps in MySQL in the CREATE TABLE command? I have 2 timestamps, one for when the record was entered, the other for any subsequent...
1
3182
by: gnuoytr | last post by:
i can't find either confirmation or contradiction in the docs available. a colleague asserts that a column defined TIMESTAMP is always and automatically updated when any column in the row is...
6
1761
by: Greg Collins [MVP] | last post by:
For background, please refer to my original thread: http://groups.google.com/groups?selm=efe5w7tYEHA.3112%40tk2msftngp13.phx.gbl I've thought of a potential way around the issue, but I'm new to...
5
5356
by: pankaj_wolfhunter | last post by:
Greetings, In Sybase, a timestamp column is automatically loaded by the DB engine and its in some hex format. This is shown below id timestamp_value ----------- ------------------ 1...
2
4470
by: Reddog | last post by:
Hi all, I have a number of tables that I want 'timestamped' with both a modified and created 'timestamp' field. Ideally both fields should 'work if ignored' in insert and updates, thus the...
7
6088
by: JJ | last post by:
How do I set one field to have the updated timestamp, and another to have the created timestamp? I want to do this directly from code generated from DB Designer if possible?! JJ
5
31281
by: Jeff Shantz | last post by:
Hello, I am working with DB2 v9, and I am looking to create a TIMESTAMP column in one of my tables that will automatically insert the current date/time when I add a new row. Is there a way to...
1
11870
by: Frank Swarbrick | last post by:
We're trying to take advantage of the new ROW CHANGE TIMESTAMP option. Here is a simple table: CREATE TABLE "ACCTASGN"."NUMBER_STATUS" ( "STATUS_CODE" CHAR(1) NOT NULL , "STATUS_DESCRIPTION"...
5
4824
by: Henry J. | last post by:
I know this could be a dumb question, I just want to confirm that it is faster to execute inserts, if a timestamp field is set to have a default value, like DEFAULT CURRENT TIMESTAMP, and skip that...
0
7258
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7313
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6970
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7441
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5558
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4987
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
1489
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
720
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
366
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.