ORA-06546: DDL statement is executed in an illegal context

Cause : DDL statement is executed dynamically in illegal PL/SQL context. - Dynamic OPEN cursor for a DDL in PL/SQL - Bind variable's used in USING clause to EXECUTE IMMEDIATE a DDL - Define variable's used in INTO clause to EXECUTE IMMEDIATE a DDL

Action - How to fix it : DBA Scripts :: www.high-oracle.com/scripts

Use EXECUTE IMMEDIATE without USING and INTO clauses to execute the DDL statement.

update : 24-04-2017

ORA-06546 - DDL statement is executed in an illegal context
ORA-06546 - DDL statement is executed in an illegal context

  • ora-36885 : (XSSRF04) Error rewriting OLAP DML expression. Column name too big
  • ora-39103 : Timeout before worker process string finished initialization. Worker error:
  • ora-37152 : MDX query error: (string)
  • ora-37012 : (XSACQUIRE_TIMEOUT) Object workspace object is locked by another user and the WAIT timed out.
  • ora-06772 : TLI Driver: error sending command
  • ora-12663 : Services required by client not available on the server
  • ora-07548 : sftopn: Maximum number of files already open
  • ora-23443 : missing template parameter
  • ora-09981 : skxfqdreg: Error Adding a page to the SDI buffer pool
  • ora-06747 : TLI Driver: error in listen
  • ora-02094 : replication option not installed
  • ora-19853 : error preparing auxiliary instance string (error string)
  • ora-27019 : tape filename length exceeds limit (SBTOPMXF)
  • ora-06138 : NETTCP: error during connection handshake
  • ora-09787 : sllfop: unrecognizable processing option, incorrect format.
  • ora-06955 : Number of database servers exceed limit
  • ora-22894 : cannot add constraint on existing unscoped REF columns of non-empty tables
  • ora-38415 : invalid name or datatype for the attribute: string
  • ora-13416 : invalid geometry parameter
  • ora-06032 : NETDNT: connect failed, access control data rejected
  • ora-06757 : TLI Driver: server got bad command
  • ora-19266 : XQ0046 - invalid URI
  • ora-00020 : maximum number of processes (string) exceeded
  • ora-02179 : valid options: ISOLATION LEVEL { SERIALIZABLE | READ COMMITTED }
  • ora-31600 : invalid input value string for parameter string in function string
  • ora-02215 : duplicate tablespace name clause
  • ora-13112 : cannot delete topo_geometry layer [string] from topology
  • ora-01650 : unable to extend rollback segment string by string in tablespace string
  • ora-36964 : (XSRELTBL09) workspace object is not a valid level relation.
  • ora-39763 : stream must be completely loaded before it is reset
  • Oracle Database Error Messages

    Oracle Database High Availability Any organization evaluating a database solution for enterprise data must also evaluate the High Availability (HA) capabilities of the database. Data is one of the most critical business assets of an organization. If this data is not available and/or not protected, companies may stand to lose millions of dollars in business downtime as well as negative publicity. Building a highly available data infrastructure is critical to the success of all organizations in today's fast moving economy.

    Well, the reason for above error is that i have taken the above script from a 11g database and running it on 10g database. 11g has bring some changes in password management. Below code is executed on 11g and user created successfully, which is expected result.