Oracle的sql developer创建好表格后如何输入多行数据
insertintocustomers(customer_id,first_name,last_name,dob,phone_number)values(2,'Cynth...
insert into customers (
customer_id, first_name, last_name, dob, phone_number
)
values
(2,'Cynthia','Green','02-Feb-1968','4143991092');
(3,'Steve','White','16-Mar-1971','800-555-1213');
(4,'Gail','Black','20-Apr-1973','800-555-1217');
(5,'Doreen','Blue','20-May-1970','800-555-1211');
(6,'Fred','Brown','01-Jan-1970','800-555-1210');
(7,'奂超','胡','09-Feb-1992','+8618979140462');
(8,'Michael','Hu','09-Feb-1992','414-7361258');
有报错ora 00928 展开
customer_id, first_name, last_name, dob, phone_number
)
values
(2,'Cynthia','Green','02-Feb-1968','4143991092');
(3,'Steve','White','16-Mar-1971','800-555-1213');
(4,'Gail','Black','20-Apr-1973','800-555-1217');
(5,'Doreen','Blue','20-May-1970','800-555-1211');
(6,'Fred','Brown','01-Jan-1970','800-555-1210');
(7,'奂超','胡','09-Feb-1992','+8618979140462');
(8,'Michael','Hu','09-Feb-1992','414-7361258');
有报错ora 00928 展开
2个回答
展开全部
你这个要写成多个insert语句的,每个语句间分号隔开。
追问
是insert into customers values(2,'Cynthia','Green','02-Feb-1968','4143991092');这样吗?需不需要保留 ( customer_id, first_name, last_name, dob, phone_number )这部分?
追答
如果整个表只有这些字段,就不用保留,如果还有其余字段,就一定要保留。
我建议你还是保留
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询