oracle Insert 一次插入多条记录有两种方法: 1)Insert All Into table_name values ... insert all into table_name values(') into table_name values(') from dual; 2)Insert Into table_name select from insert into table1_name ' from table2_name t1 '…
写一条存储过程,实现往User中插入一条记录并返回当前UserId(自增长id) --推荐写法 if(Exists(select * from sys.objects where name=N'Usp_InsertedID')) drop proc Usp_InsertedID go create proc Usp_InsertedID as insert into [User] output inserted.UserID values(N'张三蛋',3) --另一种写法(SCOPE_IDEN…