I have inserted into my table using below query in sql developer :
Insert into test (ID,TEST_NAME,TEST_DB_NAME,TEST_TABLE_NAME,TEST_TYPE,TEST_STATEMENT,TEST_DT,TEST_VERSION_DT)
values
('LEONAME','BDW','PT','GRP_UPD','INSERT','UPDATE TEST_PROD_GRP sd
set DT = TO_DATE (''01.01.2000'', ''dd.mm.yyyy'')
where DT =
( select min(DT)
from TEST_PROD_GRP sd2
where sd.ID = sd2.ID
and NAME= ''AE''
);
',to_date('15-AUG-17 06.21.22','DD-MON-RR HH.MI.SS'),to_date('15-AUG-17 06.21.22','DD-MON-RR HH.MI.SS'))
Now when i try to execute this update statement which i have inserted into table i am getting error as
"ORA-06550: line 9, column 1:
PLS-00103: Encountered the symbol ";" when expecting one of the following:
( begin case declare end exception exit for goto if loop mod
null pragma raise return select update while with
<an identifier> <a double-quoted delimited-identifier>
<a bind variable> << continue close current delete fetch lock
insert open rollback savepoint set sql execute commit forall
merge pipe purge
The symbol "exit" was substituted for ";" to continue."
When i view the update statement i can see the double quotes are applied bydefault which i believe seems to be causing the issue and i dont know how i can remove this in my insert statement:
"UPDATE TEST_PROD_GRP sd
set DT = TO_DATE ('01.01.2000', 'dd.mm.yyyy')
where DT =
( select min(DT)
from TEST_PROD_GRP sd2
where sd.ID= sd2.ID
and NAME= 'AE'
);
"