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

  • SEARCH
  • Home
  • 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 8285027
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T11:19:29+00:00 2026-06-08T11:19:29+00:00

Actually i am facing a problem calling a stored procedure and making some changes

  • 0

Actually i am facing a problem calling a stored procedure and making some changes in the database in the same transaction. What i am doing is that i insert some data from en EJB (3.0) using jpql into an oracle database and than i call a stored procedure with a native jpa query to make some processing with the fresh data. But the problem is that the PL/SQL function doesn’t see changes unless i commit the transaction and than i make the call what i don’t want to do because i want to keep all changes in the same transaction. So the question is : is there any way to insert my data, call the pl/sql function and commit everything after that (or eventually roll back all changes) ?

thank you for your help

  • 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-06-08T11:19:32+00:00Added an answer on June 8, 2026 at 11:19 am

    Make sure to call entityManager.flush() before executing your stored procedure. Else, the persistence context might still have pending changes in memory. Flushing makes sure all the pending changes are written to the database.

    If that doesn’t work, then it means that the stored proc uses a different transaction than the one used by JPA.

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

Sidebar

Related Questions

I am facing some problem with MySQL database. actually It was fast when I
Actually, I am facing a problem in Android. I am creating an application that
Facing some problem in setting up future date. Actually I m trying to do
I need a help more.Actually i am facing a problem for my listview that
I'm facing following problem actually: I'm using Spring with jQuery. I have Controller: @Controller
I have facing problem in scrolling webview in verticlly, actually i have scroll view
I am facing a problem while making Excel's LinEST function. My program goes like
I am facing a problem creating a Json which is actually a complex one
I want to concatenate a string but i am facing problem. Actually i have
I am facing some problem with ListView , I have inflated a layout with

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.