Dear All,
I have to alter a table in production database. Then associated objects
become invalid. So I want to rebuild by using below script:
spool on
Spool D:\amit\CalendarRegistration\ForRelease\SpoolText.txt
select
'ALTER ' || OBJECT_TYPE || ' ' ||
OWNER || '.' || OBJECT_NAME || ' COMPILE;'
from
all_objects
where
status = 'INVALID'
and
object_type in ('PACKAGE','FUNCTION','PROCEDURE')
;
but it is giving error like
SP2-0734: unknown command beginning "'ALTER ' |..." - rest of line
ignored.
SP2-0734: unknown command beginning "OWNER || '..." - rest of line
ignored.
SP2-0042: unknown command "from" - rest of line ignored.
SP2-0734: unknown command beginning "all_object..." - rest of line
ignored.
SP2-0044: For a list of known commands enter HELP
and to leave enter EXIT.
SP2-0042: unknown command "where" - rest of line ignored.
SP2-0734: unknown command beginning "status = '..." - rest of line
ignored.
SP2-0042: unknown command "and" - rest of line ignored.
SP2-0734: unknown command beginning "object_typ..." - rest of line
ignored.
SP2-0044: For a list of known commands enter HELP
and to leave enter EXIT.
Please help me on this issue.
Thanks,
Amit
This e-mail is confidential and may be legally privileged. If you are not the intended recipient, please notify the sender immediately and delete this e-mail.
?????????????????????????????????????????????????????????????????????????????????????????????????????????????????????
Oracle LazyDBA home page