Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

insert record

Status
Not open for further replies.

filipel

Programmer
Aug 13, 2007
42
PT
i have this table with auto increment id

DROP TABLE IF EXISTS `junta`.`subdominios`;
CREATE TABLE `junta`.`subdominios` (
`id` int(10) unsigned NOT NULL auto_increment,
`nome` varchar(45) NOT NULL default '',
`descricao` varchar(45) NOT NULL default '',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

if it is an auto-increment id.How to insert a record without specifying it?
 
Code:
INSERT 
  INTO junta.subdominios 
     ( nome , descricao )
VALUES 
     ( 'Todd' , 'Neighbour' )
   , ( 'Biff' , 'Tennis pro' )
   , ( 'Fred' , 'Milkman' )


r937.com | rudy.ca
 
thanks.Afterall i had been deceptive was in the table name
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top