MySQL Forums
Forum List  »  Newbie

Re: quickie.. query from version 3 into version 4.1?
Posted by: Erin ONeill
Date: July 29, 2005 03:57PM

Guess what I discovered today!! When I take my carefully crafted CREATE TABLE script and run it to create my table. MySQL does some things that I really don't remember Oracle doing at all. And here all this time I thought it was phpMyAdmin! (sorry phpMyAdmin!)

Here's my create script:
CREATE TABLE log_table (
id int(11) NOT NULL auto_increment,
ip_address char(15) NOT NULL,
running_time int NOT NULL,
member_name varchar(25) NOT NULL,
member_group varchar(25) NOT NULL default 'user',
PRIMARY KEY (id),
KEY runningtime(running_time)
);

Here's what MySQL shows me when I do a show create table cmd:
CREATE TABLE `log_table` (
`id` int(11) NOT NULL auto_increment,
`ip_address` varchar(15) NOT NULL default '',
`running_time` int(11) NOT NULL default '0',
`member_name` varchar(25) NOT NULL default '',
`member_group` varchar(25) NOT NULL default 'user',
PRIMARY KEY (`id`),
KEY `runningtime` (`running_time`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1

HEY!!! I didn't put all those defaults in there. I only put the ONE default. So I'm driving myself crazy over something MySQL does and not people. sigh. ok, learned something new today.

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.