[jboss-user] [Datasource Configuration] - how can i get ParameterMetaData?

lei shi do-not-reply at jboss.com
Mon Jan 3 06:48:02 EST 2011


lei shi [http://community.jboss.org/people/ivinter] created the discussion

"how can i get ParameterMetaData?"

To view the discussion, visit: http://community.jboss.org/message/577826#577826

--------------------------------------------------------------
when i use jboss 5.1,and deploy a datasource,and my code is :
Connection conn=DBConection.getInstance().getConnection();
   CallableStatement csmt = null;
   String proName = "";
   proName = "{call sp_add(?,?,?)}";
   csmt = conn.prepareCall(proName);
   csmt.clearParameters();
   ParameterMetaData pmd = csmt.getParameterMetaData();
   for (int j = 0; j < 3; j++) {
    System.out.println(pmd.getParameterClassName(j + 1));
   } 

ParameterMetaData pmd = csmt.getParameterMetaData();
i get org.jboss.resource.adapter.jdbc.remote.SerializableParameterMetaData ,not java.sql.ParameterMetaData

why?

i want to invoke pmd.getParameterClassName(),but org.jboss.resource.adapter.jdbc.remote.SerializableParameterMetaData does not have such method.
--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/577826#577826]

Start a new discussion in Datasource Configuration at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2077]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110103/e99151a4/attachment-0001.html 


More information about the jboss-user mailing list