Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 583959
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T14:50:53+00:00 2026-05-13T14:50:53+00:00

I am getting Following when query executing on through web application java.sql.SQLException: ORA-04031: java.sql.SQLException:

  • 0

I am getting Following when query executing on through web application

java.sql.SQLException: ORA-04031:
java.sql.SQLException: ORA-04031: unable to allocate 48784 bytes of shared memory ("shared pool","SELECT   emplid levempid, '2...","Typecheck","qry_text : qcpisqt")

But same query is executing through TOAD properly.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-13T14:50:54+00:00Added an answer on May 13, 2026 at 2:50 pm

    Chances are very high that your Java code is not making use of bind variables. In that case each SQL statement is unique and will not be reused, thrashing the shared pool. It will become fragmented and finally results in the ORA-04031.

    Restarting the database will only temporarily work, but eventually you will run into the same problems. Increasing the shared pool size and regularly restarting the database is not a real solution. Only real solution is to rewrite your SQL to use bind variables.

    Here is an AskTom thread of someone experiencing something similar: http://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:528893984337

    And a nice little program to track which SQL statements are not making use of bind variables can be found in this thread: http://asktom.oracle.com/pls/apex/f?p=100:11:0::::P11_QUESTION_ID:1163635055580

    Hope this helps.

    Regards,
    Rob.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 537k
  • Answers 537k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer -(void)startTask; appears to be private implementation and in theory should… May 17, 2026 at 1:48 am
  • Editorial Team
    Editorial Team added an answer Convert it to Calendar and use Calendar#getActualMaximum() to obtain last… May 17, 2026 at 1:48 am
  • Editorial Team
    Editorial Team added an answer This is likely caused by the vertical spacing and/or margins… May 17, 2026 at 1:47 am

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

I am getting the following error while executing the following query in an Stored
I'm getting a syntax error on the following query: SELECT 1,2 WHERE 1=1 But
I have an issue with the MySQL SOURCE command. I am getting the following
Hello Friends i have the following query which defeat the very purpose. A day
I'm using SQL Server 2005 Analysis Services and I'm trying to calculate distance inside
For example I have the following tables resulting from: CREATE TABLE A (Id int,
I am attempting to create a dynamic query using expression trees in LINQ to
how can i check current number in mysql where.... my query is $aid =
This wiki post outlines both a problem and a solution. I wanted to post
I'm currently in the process of detaching a development database on the production server.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.