you got me...
according to the PL/SQL manual:
By extending SQL, PL/SQL offers a unique combination of power and ease of
use.
You can manipulate Oracle data flexibly and safely because PL/SQL fully
supports
all SQL data manipulation statements (except EXPLAIN PLAN), transaction
control
statements, functions, pseudocolumns, and operators.
and, as EXPLAIN plan does no commit, ROLLBACK does clear the uncommitted
rows from the PLAN_TABLE
good call
- mcs
"Yong Huang" <yong321_at_yahoo.com> wrote in message
news:b3cb12d6.0311070706.77946620_at_posting.google.com...
> Actually, EXPLAIN PLAN is not a DLL [DDL], because it doesn't modify data
> dictionary. And it doesn't commit your transaction. So I guess we can
> only say it *is* a DML. EXECUTE IMMEDIATE works for DML and queries
> too.
>
> Yong Huang
>
> "mcstock" <mcstockspamplug_at_spamdamenquery.com> wrote in message
news:<ecKdnYRoOPL32TeiRVn-jA_at_comcast.com>...
> > good catch, thomas
> >
> > and the reason is that, although EXPLAIN PLAN is typically issues via
> > SQL*Plus, it is not a SQL*Plus command, but a legal SQL statement -- but
> > since it is not a DML statement, it is not directly supported by PL/SQL
> >
> > -- mcs
> >
> > "Thomas Wagner" <twa_priv_at_yahoo.com> wrote in message
> > news:f695d6a3.0311052148.7a3abcea_at_posting.google.com...
> > > idogan_tech_at_yahoo.com (Ibrahim DOGAN) wrote in message
> > news:<6bf58828.0311050646.44eb8cbb_at_posting.google.com>...
> > > > is it possible to run "explain plan" command within a PL/SQL block ?
> > > >
> > > > thanks,
> > > > i.d.
> > >
> > > What about this:
> > >
> > > begin
> > > execute immediate 'explain plan for select * from dual';
> > > end;
> > > /
> > >
> > > Regards
> > > Thomas
Received on Fri Nov 07 2003 - 10:25:15 CST