我没有用oracle写过很多存储过程。我通读了一些教程(例如:http://plsql-tutorial.com/plsql-procedures.htm )并尝试根据我所看到的对我的 sp 进行建模,但我仍然遇到错误。这是一个小示例程序和错误:
create or replace
PROCEDURE TEST_SP()
BEGIN
insert into tablespace.tablename
select * from testtable;
END TEST_SP;
PLS-00103: Encountered the symbol ")" when expecting one of the following:
<an identifier> <a double-quoted delimited-identifier>
我的印象是我错过了声明部分,但我不明白我应该声明什么:-/
任何帮助,将不胜感激。
从第一反应遵循贾斯汀的建议,现在得到不同的错误:
create or replace
PROCEDURE TEST_SP
AS
BEGIN
insert into tablespace.tablename (col1, col2)
select (col1, col2) from testtable;
END TEST_SP;
PLS-00103: Encountered the symbol "AS" when expecting one of the following:
. , @ in <an identifier> <a double-quoted delimited-identifier> partition subpartition