I have a program that uses connection pooling to connect to the database.I have 3 datasource files web-ds.xml, proxy-ds.xml, proxy-backup-ds.xmlData source files are deployed in %JBOSS_HOME%/server/all/deploy folder.I am trying to access the datasource but I am getting an error. By seeing the Datasource file and Code to access it , could you pinpoint the error.[Error message is given lastone of it the datasource file looks as suchweb-ds.xml

The lack of formatting for the source code (you did not use the 'code' tags to maintain indentation) and the use of bold text makes your post extremely difficult to read. I cannot tell if you have one or more source files, what text is your comments/questions and what is source code - it all just runs together. If you want help, you have to make it easier for us to help you - we are all very busy and having a post that is difficult to read means that the post will be ignored.

Question:----Reson for this error? Is there an error in my code or error in my Connection pooling (XML) files? am I using the right procedure to lookup the connection? Is thre an eroor in closing the connections in finally block(cause I usually see error at that line of code in jboss log)?

Explanation of my projectI have three different XML files each pointing to a Progress database.1) web-ds.xml 2) proxy-ds.xml 3) proxy-backup.xml

Here is a sample of one of my web-ds.xml file which I am using to connecting to Progress. I have deployed the file in %JBOSS_homw%/server/all/deploy.

web-ds.xml

<local-tx-datasource><jndi-name>web-ds</jndi-name><connection-url>jdbc:JdbcProgress:T:qad3:15330:trnwebeb2</connection-url><driver-class>com.progress.sql.jdbc.JdbcProgressDriver</driver-class><user-name>webproxy</user-name>yxorpbew<min-pool-size>5</min-pool-size><!-- The maximum connections in a pool/sub-pool --><max-pool-size>20</max-pool-size><idle-timeout-minutes>20</idle-timeout-minutes><!-- sql to call on an existing pooled connection when it is obtained from pool--> <check-valid-connection-sql>SELECT COUNT(1) FROM pub.zzad_ctrl</check-valid-connection-sql><!-- Whether to check all statements are closed when the connection is returned to the pool, this is a debugging feature that should be turned off in production --><track-statements>true</track-statements><!-- HSQL DB benefits from prepared statement caching --> <prepared-statement-cache-size>32</prepared-statement-cache-size><!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml -->

First, you did not use the 'code' tag like I asked you to. Enclose both Java source code and XML text in UBBCode "code" tags - you can do this by selecting the XML text and clicking the Code button above the editor window. Also, click the Preview button to ensure that the formatting is correct and the XML text shows up before posting.

which as far as I can tell is the first entry in the stack that does not come from Progress or JBoss, and so I assume that this code is yours. Yet you did not post this code. When you do post the code, highlight line 3534. Also, have to examined your code to find out where it is closing the result set?

Now, you might point out that I am ignoring the other exceptions, which is true - one should always tackle the first error first and only when that error is fixed tackle the next error, if that error still appears - quite often they are a side-effect of the first error.

Looks like you are closing your result sets in the finally block. Are you, by any chance, getting an exception, which is being catch by these lines:

}catch (Throwable e) {
throw new ErpProxyDaoException (e);

I suspect that there was an issue earlier that caused an exception to be thrown before the result set was opened. But it appears that the connection was successfully open, which explains the "Closing a statement you left open, please do your own housekeeping " warning. Your "finally" block should have try/catch statements around each xxx.close() statement to prevent this.