Tab navigation
- Required IBM i PTFs
- Client/Server Communication
- JDBC
- Record-level access
- Integrated file system
- Graphical Toolbox
- Java Related
Required IBM i PTFs
Are the required IBM i PTFs on your system?
Client/Server Communication
- Is there an active TCP/IP connection between your client and IBM i system that is not blocked by a firewall? 'Ping' your IBM i system from your workstation to see if the connection is active. Also 'ping' your workstation from the IBM i system. The Toolbox also provides a class called JPing, in the utilities package, which can be used to determine if a TCP/IP connection can be made to the IBM i host servers.
- Are the IBM i host servers started ? The IBM Toolbox for Java classes use the IBM i host servers as the access point to IBM i data. Use "STRHOSTSVR *ALL" from an IBM i command prompt to start the servers. The file and database servers run in the QSERVER subsystem. If not already started, run "STRSBS QSERVER" from an IBM i command prompt to start the subsystem before starting the servers. Use "STRTCPSVR *DDM" from an IBM i command prompt to start the DDM server, which is used by Record Level Access classes such as KeyedFile and SequentialFile.
- Is the QUSER user profile enabled and does it have a valid password? The IBM i host servers pre-started jobs begin under the QUSER profile. Once the Toolbox connects to the host server, the server job swaps to the user profile supplied by the Java program or entered on the toolbox sign-on dialog. QUSER must be enabled and have a valid password.
Troubleshooting JDBC
- Does your program receive exception "No suitable driver found" when it tries to access an IBM i database?
You must you register the IBM Toolbox for Java JDBC driver with the DriverManager class. To register the driver add
DriverManager.registerDriver(new
com.ibm.as400.access.AS400JDBCDriver());
to your program, or add
com.ibm.as400.access.AS400JDBCDriver
to the JDBC.drivers property.
Class.forName(new com.ibm.as400.access.AS400JDBCDriver()) does not register the JDBC driver on some JVMs. See Sun's JDBC FAQ (link resides outside of ibm.com) for more details.
- Does your program receive "com.ibm.as400.access.AS400JDBCException: [PWS0001] Function did not complete successfully" when it accesses an IBM i database file?
Make sure the latest IBM i database server PTFs are applied to the IBM i system. This message usually indicates an error in the database server. - Does your program fail when it tries to execute a stored procedure using the Toolbox JDBC driver? Does your program receive "java.sql.SQLException: Descriptor index not valid"?
- Make sure the procedure exists on the IBM i.
- For the location of the procedure, make sure the schema name is used, not the library name.
- Make sure the procedure being called does not expect input parameters.
Troubleshooting Record-Level Database Access
- The record-level access classes will not function if the host servers aren't started on the IBM i system. Run "STRHOSTSVR SERVER(*ALL)" from an IBM i command prompt to start the servers.
- For V4R2 and later, the record-level access classes will not function if the DDM server is not started on the IBM i system. Run "STRTCPSVR SERVER(*DDM)" from an IBM i command prompt to start the server.
- The record-level access classes will not function if the "DDM Request Access" network attribute is set to *REJECT. Run "DSPNETA" from an IBM i command prompt to make sure this attribute is set to *OBJAUT.
- By default, the record-level access server runs in the QSYSWRK subsystem. Run "STRSBS QCMN" from an IBM i command prompt to start the server.
- When using KeyedFile, the key value for character fields that are not variable length must be blank padded to the fixed length of the field.
Troubleshooting Integrated File System Classes
- What object types in the QSYS.LIB directory can be manipulated? In general, the file server on IBM i does not allow objects in the QSYS.LIB file system to be opened for data access. The contents of these objects (such as user profiles, job descriptions, data queues, device descriptions, etc.) cannot be read or written. The exception is source physical file members and user spaces. The data in these two types of objects can be read and written.
Troubleshooting the Graphical Toolbox
- Instructions for non-English Graphical Toolbox Developers
For non-English Graphical Toolbox developers, there is a problem where the message viewer will display properly with the correct translated strings, but the panel is constructed using the English layout. Using the English layout means that strings on the panel will be truncated for NLVs that require that the panel be enlarged to accommodate longer strings (for example, Germany).
To correct this, Non-English Graphical Toolbox developers must copy two files from the Toolbox directory on the IBM i system to their local machines.
To correct this, Non-English Graphical Toolbox developers need to manually copy the following files from the Toolbox directory on the IBM i system (/QIBM/ProdData/HTTP/Public/jt400/MRI29xx/) to their local machines:
IDD_CM_MESSAGE_DETAILS_locale.pdml.ser
IDD_CM_MESSAGE_VIEWER_locale.pdml.ser
Java Related
- Your Java Virtual Machine must support JVM 1.1.8 or later.
- If accessing the class files from a Java program, jt400.jar must be in your classpath.
- When running an applet in a browser, do you see error java.io.FileNotFoundException for "/com/ibm/as400/access/MRI.class"? You can ignore this error. The Toolbox uses property resource bundles for its messages. When the Toolbox loads its messages, the browser first tries to find file MRI.class before it looks for MRI.properties. The messages are in MRI.properties. The Toolbox will function properly even though the error is displayed.
