在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
关键是不能换行,要加上begin ...sql... end; 每个SQL用;隔开,end后面必须加; 以下是拷贝于:http://www.cnblogs.com/teamleader/archive/2007/05/31/765943.html 有时我们需要一次性执行多条sql语句,而用来更新的sql是根据实际情况用代码拼出来的 begin update TB_VG set seq = 1, vessel_id = 'Jin14', vessel_type = 'TRACK' where batch_number = '20837' and train_id = '0233086'; update TB_VG set seq = 2, vessel_id = 'Jin14', vessel_type = 'TRACK' where batch_number = '20992' and train_id = '0233110'; end; 总结如下: 以begin开始,以end;结尾(end后的分号不能省),中间的每个sql语句要以分号;结尾 ORA-00933: SQL 命令未正确结束(如果sql没有以分号结尾) 关键是不能换行,要加上begin ...sql... end; 每个SQL用;隔开,end后面必须加; 以下是拷贝于:http://www.cnblogs.com/teamleader/archive/2007/05/31/765943.html 有时我们需要一次性执行多条sql语句,而用来更新的sql是根据实际情况用代码拼出来的 begin update TB_VG set seq = 1, vessel_id = 'Jin14', vessel_type = 'TRACK' where batch_number = '20837' and train_id = '0233086'; update TB_VG set seq = 2, vessel_id = 'Jin14', vessel_type = 'TRACK' where batch_number = '20992' and train_id = '0233110'; end; 总结如下: 以begin开始,以end;结尾(end后的分号不能省),中间的每个sql语句要以分号;结尾 ORA-00933: SQL 命令未正确结束(如果sql没有以分号结尾) |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论