INSERT into a Database :
Query:
insert into tablename values (column1,column2,column3,.........)
(or)
insert into tablename(column1, column2....) values (data1 , data2......).
Example :
insert into tablename values (1,'jeeva','Junior S/W Engg',11000,999999999)
(or)
insert into tablename (id,name,Designation,salary,mobile)values(1,'jeeva','Junior S/W Engg',11000,999999999) .
insert into tablename values (column1,column2,column3,.........)
(or)
insert into tablename(column1, column2....) values (data1 , data2......).
Example :
insert into tablename values (1,'jeeva','Junior S/W Engg',11000,999999999)
(or)
insert into tablename (id,name,Designation,salary,mobile)values(1,'jeeva','Junior S/W Engg',11000,999999999) .
INSERTING into a Particular Column in a Database :
Query:
insert into tablename (column1) values ('data').
Example : insert into tablename (name) values ('john')
// executing this query will insert only john in second row ,rest of the columns will be set as NULL by default //
insert into tablename (column1) values ('data').
Example : insert into tablename (name) values ('john')
// executing this query will insert only john in second row ,rest of the columns will be set as NULL by default //
No comments:
Post a Comment