2 Replies Latest reply: Mar 28, 2012 7:03 PM by rp0428 RSS

    Change the query time limit

    Neal
      Hi,

      We have some sessions in 11g DB which runs SELECT statements for long time ( 2 > ).

      Is there a way we can limit the query time to force to timeout at session level? Wondering is there a session parameter where we can change by running a cmd in relevent sessions.

      Thanks!
        • 1. Re: Change the query time limit
          Srini Chavali-Oracle
          You can use PROFILEs or the RESOURCE MANAGER

          http://docs.oracle.com/cd/E11882_01/server.112/e26088/statements_6010.htm
          http://docs.oracle.com/cd/E11882_01/server.112/e25494/dbrm.htm

          HTH
          Srini
          • 2. Re: Change the query time limit
            rp0428
            >
            Is there a way we can limit the query time to force to timeout at session level?
            >
            This link to a thread in this same forum has detailed code that demonstrates this. It is too length to copy it here.
            Resource plan to limit execution time
            This was the original question
            >
            Can anyone guide me how should i create a resource consumer group/resource plan and assign to my user "dev" so that any query run by this user should not take more than 10 minutes for execution and should abort if execution time exceeds 10 minutes