Level: Intermediate David Muir, iSeries Application Development , IBM Toronto Lab, Canada
06 May 2003 This question and answer article features David Muir, Information Development manager for the WebSphere Development Studio Client for iSeries team. He discusses tool differences, error messages, storage pools, encoding, and more.
Introduction
This month we ask David Muir to answer your questions about the features
of WebSphere® Development Studio Client for iSeries and the best ways to leverage your current RPG and COBOL knowledge in a Web world.
WebSphere Development Studio offers an integrated environment for creating and maintaining
iSeries host applications while enabling you to make the leap into e-business.
David is manager of Information Development for the WebSphere Studio for iSeries team.
For more information, see WebSphere Studio Zone. David would like to thank the following colleagues for their help in preparing this article:
Violaine Batthish, Phil Coulthard, Mike Hockings, George Silber, and Don Yantzi.
We appreciate and thank all the WebSphere developers who submitted questions. Question: What is the plan to keep WebSphere Development Studio in synch with
Eclipse releases? Answer: The plan is to keep WebSphere Development Studio and the entire
WebSphere Studio family of products in synch with WebSphere Application Server, as opposed to Eclipse.
In this way, the version of the tools will match the version of the application server. The current
release of Eclipse is used at the time of a product release. This will only be a few
months behind the Eclipse release. Question: What is the difference between the IBM WebFacing Tool and
the HATS LE function that was announced in January 2003? Answer: HATS LE converts the 5250 datastream into HTML at runtime.
It is like an emulator in that it is "session" based. All screens in your session are converted
to HTML as you use it. WebFacing converts the DDS source, not the 5250 datastream, and it does
this conversion at development time, not run time. WebFacing is intended for enabling a particular
application for the Web, while HATS is intended for accessing your system from the Web. Question: We have WebSphere Application Development Tools.
What is the difference between those and WebSphere Development Studio Client? Answer: We have had several products with similar names in the last few years.
WebSphere Studio Application Developer and WebSphere Development Tools for iSeries are both products.
If you mean WebSphere Studio Application Developer, then that is a superset of WebSphere Studio Site Developer,
adding support for Enterprise Java Bean (EJB) development. Our product is built on top of WebSphere Studio
Site Developer, adding special iSeries function. If you want to do EJB development and want iSeries function,
choose WebSphere Development Studio Client, Advanced Edition, which is built on top of WebSphere Studio
Application Developer.
If you mean WebSphere Development Tools for iSeries, then that was the predecessor to WebSphere Development
Studio Client, offering early versions of much of the same function. Question: We use Websphere 5 Connection Pooling & statement cache
and JTOpen 3.3. Would you please explain how "Websphere prepared statement cache"
is compared to "J pen Dynamic statement cache
(using Extended dynamic property + PACKAGE = true)". We use both when configuring JDBC Provider and datasource for iSeries v5r1.
We use open new connections to AS/400 and prepare all our statements, through a loop.
Only in the first connection we get these messages through the console:
Creating package [DAMAGE719].
Package [DAMAGE719] already exists.
Caching package [DAMAGE719]
And during the statement preparing:
Statement [...] was found in the cached package as QZ85D2160DD426FEC8.
The next Connections have the following messages:
as400: Connection SAHAR (688930286) : Creating package [DAMAGE719].
as400: Connection SAHAR (688930286) : Package [DAMAGE719] already exists.
as400: Connection SAHAR (688930286) : Caching package [DAMAGE719].
SQLWarning: reason(Package caching is not being used.) SQLstate(01H12) vendor code(-99999)
as400: static method: Posting warning, sqlState: 01H12 reason: Package caching is not
being used. vendor code -99999.
java.sql.SQLWarning: Package caching is not being used.
at com.ibm.as400.access.JDError.getSQLWarning(JDError.java:292)
|
And the prepared statements are not retrieved from the cache! - Why only the first connection uses the cached package?
- Is JTOpen SQL PACKAGE redundant when using WebSphere prepared statement cache?
(submitted by Hertzel Karbasi, OPTinity eSolutions Ltd.) Answer: This should work (in other words, you should not see the error).
However, it is redundant. If you wish to get to the bottom of the error, go to IBM service. This is a
Toolbox (or QSERVER) problem.
However, as far as using WebSphere Application Server prepared statement cache or
extendedDynamic/packageCache, we would use the
AS prepared statement cache as it caches the Java PreparedStatement objects with the connection.
This follows the "prepare once execute many" philosophy. In our opinion, the
extendedDynamic/packageCache provides you no additional advantage when used with Application Server connection
pooling and statement cache. You do have the option to turn one off and use the other, but neither
is intended to be used in conjunction with the other. Question: I got "SQLException: No suitable driver."
How can I debug it? Here's my story. I was running a servlet generated by the
Create Database Web Pages wizard within the WebSphere Test Environment.
I changed web.xml for my project as I would like to access an AS400 database remotely.
I used AS400JDBCDriver from jt400.jar.
I imported jt400.jar into my project.
I used Add Exteral JAR to have c:\WDSC\WSDD\plugin\...\jt400.jar inside
the ws.ext.dirs panel. How should I proceed if I want to start all over again?
(submitted by peter.liu@senecac.on.ca) Answer: "No suitable driver" is an error that usually occurs during a call
to the DriverManager.getConnection method. The cause can be failing to load the appropriate
JDBC drivers
before calling the getConnection method. Or, it can be specifying an invalid JDBC URL, one that is not
recognized by your JDBC driver.
If you suspect that the URL you are specifying is not being recognized
by your JDBC driver, check the documentation for your JDBC driver or
contact your JDBC driver vendor.
In addition, when you are using the JDBC-ODBC Bridge, this error occurs if one or more the the shared libraries
needed by the Bridge cannot be loaded. If you think this is the cause, check your configuration to be sure that the
shared libraries are accessible to the Bridge.
You must 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.
For more details, see Sun's®
JDBC FAQs. Question: The WebSphere Application Server Express for iSeries contains
Websphere Studio Client for iSeries. The announcement, ZP03-0158, for WAS Express does not mention
the licensing for the Site Developer component. Could you provide any details?
(submitted by EG) Answer: The WebSphere Application Server Express for iSeries product's license
document covers the details
of the licensing of the development tools. The Application Server Express development tools include
WebSphere Studio Site Developer found in the WebSphere Development Studio Client.
The license document states that the
development tools can be installed on a primary development workstation and one other
development workstations, but only one development workstation can be used at a time.
Basically, this means Application Server Express includes a single license for Site Developer. Question:How can I get the mouse wheel to work in Code?
It doesn't work in the Run SQL Scripts component of Client Express either, but it does
work in every other application I use. I have W2K SP2 and WDSC v4.0. (submitted by JB) Answer: In every case where this issue has been encountered before,
updating the mouse driver to the latest version has fixed the problem. Question: How do I access a source member that resides in a library that is in
an IASP in WDSc 4.0 for iSeries in remote explorer? (submitted by Brandon Wahl) Answer:
To use the Remote System Explorer (RSE) to edit a source member, which resides in an independent auxiliary
storage pool (IASP), specify the name of the independent auxiliary storage pool in the initial ASP group
field (INLASPGRP) for your OS/400 job description.
When you connect to the iSeries using the RSE, the IASP is added to the library name space for the RSE server job.
You can then access libraries, objects, and members in this IASP.
The RSE does not support dynamically setting the IASP using the SETASPGRP. Running this command in
the RSE changes the library name space for the RSE server job, but does not change the name space for the
Distributed Data Manager (DDM) server job used by the RSE to edit source members. If you change the IASP in
this way, you receive an error (RSEF1002E) when you try to open the source member. The error message indicates
that the library was not found.
Note that editing of source members from an IASP is not supported in Development Studio Client Version 4.0.
Question: How can I configure UTF-8 encoding (for Webfacing)
in WAS V5 Express? Documentation provided only
explained for WAS V3R5 and WAS V4. (submitted by PG)
Answer: If you are using a Development Studio Client V4 WebFacing project,
then you need to manually set the client encoding to UTF-8 regardless of the servlet environment.
If you are using a Development Studio Client V5 WebFacing project and the right servlet environment (2.3 or greater),
then WebFacing can set the client encoding programatically. WebSphere Application Server V5 uses a 2.3 servlet
environment, which means that the client encoding for Version 5.0 WebFacing projects does not need to be set,
regardless of the project's J2EE level. About Meet the Experts
Meet the Experts
is a monthly feature on WSDD. We give you access to the best minds in IBM WebSphere,
product experts and executives who are waiting to answer your questions. You submit the questions,
and we post the answers to the most popular questions.
Resources
About the author  | 
|  | David Muir is manager of Information Development for the WebSphere Studio for iSeries team in Toronto, Canada. |
Rate this page
|