insert的语法,使用values时,一次只能插入一条记录。
解决办法:
插入多行,一般使用insert into .... select ...,子查询的方式。
如你的例子:
一、
insert all
into students values ('0515101143','XXX','','OOOOO')
into students values ('0515102003','XX','','OOOOO')
select * from dual;
二、
insert into students
select 0515101145,'XXX','','OOOOO' from dual
union
解决办法:
插入多行,一般使用insert into .... select ...,子查询的方式。
如你的例子:
一、
insert all
into students values ('0515101143','XXX','','OOOOO')
into students values ('0515102003','XX','','OOOOO')
select * from dual;
二、
insert into students
select 0515101145,'XXX','','OOOOO' from dual
union
select 0515102005,'XX','','OOOOO' from dual;