Tell me more ×
Stack Overflow is a question and answer site for professional and enthusiast programmers. It's 100% free, no registration required.

I have a application that work with some transactions.

So I plan to use auto commit false before doing calculations and insert statements and after calling inserting I commit.

But there is error occurred and error is java.sql.SQLException: ERROR: portal "" does not exist. When I'm not using auto commit it works fine and inserting data successfully.

pseudo code is like this..

calculate(connection con)
{
    con.setAutocommit(false);
    do calculations;

    call stored procedure to insert data;

    con.commit();
}

Note: there are lot of sql statements used to gather data for calculations.

Please help me to correct this error.. what i'm doing wrong here. Thank you

stacktrace 
java.sql.SQLException: ERROR: portal "" does not exist
at com.edb.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1926)

at com.edb.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1581)

at com.edb.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:330)

at com.edb.jdbc2.AbstractJdbc2Connection.executeTransactionCommand(AbstractJdbc2Connection.java:657)

at com.edb.jdbc2.AbstractJdbc2Connection.commit(AbstractJdbc2Connection.java:677)

at quickpawn.Sp.spToPawn(Sp.java:179)

at quickpawn.newPawn.jButton2_mouseClicked(newPawn.java:1723)

at quickpawn.newPawn_jButton2_mouseAdapter.mouseClicked(newPawn.java:2110)

at java.awt.AWTEventMulticaster.mouseClicked(AWTEventMulticaster.java:212)

at java.awt.Component.processMouseEvent(Component.java:5103)

at java.awt.Component.processEvent(Component.java:4897)

at java.awt.Container.processEvent(Container.java:1569)

at java.awt.Component.dispatchEventImpl(Component.java:3615)

at java.awt.Container.dispatchEventImpl(Container.java:1627)

at java.awt.Component.dispatchEvent(Component.java:3477)

at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)

at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3207)

at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)

at java.awt.Container.dispatchEventImpl(Container.java:1613)

at java.awt.Window.dispatchEventImpl(Window.java:1606)

at java.awt.Component.dispatchEvent(Component.java:3477)

at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)

at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)

at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)

at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)

at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
share|improve this question
1  
Where does the error occur? Can you give us the stack trace? – BevynQ yesterday
Does this link pgpool.net/mantisbt/view.php?id=14 describe your problem? You could have found this with a simple Google search, which you're expected to have done before posting here. – Jim Garrison yesterday
1  
It's never of any help when ambiguous statements are added to cover up the real code. At least put the real calls in and rename things if your stored procedure names are super secret or something. – JustBob yesterday
We can't help you with your code if you don't show your code. You should also always mention the PostgreSQL version and PgJDBC version. thanks for including a full stracktrace though. In this case it looks like you're really using EnterpriseDB Postgres Plus or similar, not PostgreSQL, so you might have more luck on the EnterpriseDB forums. They don't really hang out here. – Craig Ringer yesterday
Thank you for all comments.. its postgres plus advance server 9.2.. i'm still working on this matter and find out problem with stored procedure. when i comment SP its working fine. Then I debug SP with values came up from calculations and SP also working fine. – user2164770 23 hours ago

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.