Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Multiple selects or insert statements in a single execution..
"Karthikeyan" <karthi_srs_at_rediffmail.com> a écrit dans le message news:
bodi9i$b5i$1_at_news.mch.sbs.de...
>
> "Alkos" <azerty_at_nospam.org> wrote in message
> news:bod9ed$35d3_at_news.rd.francetelecom.fr...
> >
> > "Karthikeyan" <karthi_srs_at_rediffmail.com> a écrit dans le message news:
> > bocqk4$77k$1_at_news.mch.sbs.de...
> > > Hi all,
> > > I am just a beginner to Oracle.
> > > I am wondering how to execute the multiple select statements or insert
> > > statements on different tables in a single execution.
> > >
> > > for eg.
> > > select * from Person;
> > > select * from Book_Details;
> > >
> > > The above select statements I want to execute in a single execution
and
> > not
> > > by storing these statements in some file and exectuing that file.
> > >
> > > Please help me how to solve this.
> > >
> > > Note: I can't put these select queries in a stored procedure as these
> > > queries will be dynamically generated and I need to execute these in a
> > > single execution.
> > >
> > > Regards,
> > > Karthi
> > >
> > >
> >
> > Hello,
> >
> > By saying "single execution", do you mean that both queries should be
> > executing at the same time
> > and not one after another ? What is the very purpose of what you are
> trying
> > to do ?
> >
> > Can you tell the group about which dev tools you use to "dynamically
> > generate" your queries ?
> > It will help us to answer your question.
> >
> > Alkos
> >
> >
> Hi,
> What I meant by "Single Execution" was that If I am executing these
> select statements
> from SQLPLus I don't want to give in two steps.
> Its like, at "SQL > prompt", I want to exeucte this statements in a
> batch.
> I have my own program by which when the user chooses the tables from the
> GUI, I will generate the select statements.
> Those statements I want to execute in a "single execution".
>
> Am I clear ?
>
> Thanks in Advance,
> Karthi
>
>
>
>
>
Let's assume that all your queries are in a batch, OK ?
So they'll be executed one after another as the sql script is processed by
sqlplus.
There is no other way to do unless running multiple instances of sqlplus,
each of them executing
one query. However, in this situation, you don't have any control of the
synchronization (right spelling ?)
of your queries, that is, the result of your select may be a mess.
Let's try to examine the problem from another point of view. What is the behaviour expected by the user of the GUI ?
Alkos Received on Thu Nov 06 2003 - 08:17:43 CST
![]() |
![]() |