Retrieve parameter names for stored procedures

To retrieve the names of parameters for stored procedures, use DatabaseMetaData methods defined by the JDBC specification as shown in the following example.
Connection myConn = ...   // connection to the RDBMS for Database
. . .
      DatabaseMetaData dbmd = myConn.getMetaData();
      ResultSet rs = dbmd.getProcedureColumns(
       "myDB", schemaPattern, procedureNamePattern, columnNamePattern);
      rs.next() {
          String parameterName = rs.getString(4);
 - - - or - - -
 String parameterName = rs.getString("COLUMN_NAME"); 
 - - -
          System.out.println("Column Name: " + parameterName);

The names of all columns that match the parameters of the getProcedureColumns() method are displayed.

Parameter names are not part of the ParameterMetaData interface and cannot be retrieved from a ParameterMetaData object.

When you use the getProcedureColumns() method, the query retrieves all procedures owned by informix (including system-generated routines) from the sysprocedures system catalog table. To prevent errors, verify that the stored procedures you are using have been configured with correct permissions on the server.

See Unsupported methods and methods that behave differently for important differences in JDBC API behavior for the getProcedureColumns() method.