Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: How to force query to use a specific rollback segment in java?

Re: How to force query to use a specific rollback segment in java?

From: Chris Leonard <s_p_a_m_chris_at_hotmail.com>
Date: Wed, 15 Jan 2003 16:24:46 -0600
Message-ID: <OclV9.261$%15.74193@news.uswest.net>


If by "query" you mean "select statement" (as opposed to a update, insert, or delete, for example) then your question seems meaningless. Select statements use whatever RBS's are necessary to construct the required snapshot to satisfy the query. If you are getting "snapshot too old" messages or some such thing, it is because your RBS's are not large enough to leave modified data in them long enough for your query to read them - but it is the update, insert, and delete statements that are actually loading data into the RBS's.

If, on the other hand, your query is modifying data, then your approach should work, as long as SET TRANSACTION is the first statement in the transaction.

--
Cheers,
Chris

___________________________________

Chris Leonard, The Database Guy
http://www.databaseguy.com

Brainbench MVP for Oracle Admin
http://www.brainbench.com

MCSE, MCDBA, OCP, CIW
___________________________________

"barnsley97" <sfurlong_at_altaprise.com> wrote in message
news:9b093de0.0301151302.45190b40_at_posting.google.com...

> Does anyone know how I can force oracle to use a specific rollback
> segment when executing a query from within my Java program?
>
> I want it to use this RBS because this is a rather long running open
> cursor that requires to save a snapshot in the RBS. This particular
> RBS will be much larger than the others and private (so that other
> trans can't get to it).
>
> I'm using the following statement in java, but it does not appear to
> be working.
>
> Statement stmt = dbConn.createStatement();
> stmt.execute(" Set transaction use rollback segment RBS_TEST ");
>
> Thanks in advace.
Received on Wed Jan 15 2003 - 16:24:46 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US