background image

STEP4.3

:

Create the tables in the database

To continue with the next steps 

you must have installed a database management system (i.e. DB2).

you must have a JDBC Driver for it (i.e. db2java.zip in <db2>\java\). 

you must be able to connect to the database (userid/password)

Make sure the JDBC driver is in the CLASSPATH. You may have to edit 
the 

create.bat/create.cmd/create.sh

batch files as well as the 

run.bat/run.cmd/run.sh

batch files and add the JDBC Driver Archive to 

the classpath:

set CLASSPATH=.;xerces.jar;<db2>\java\

db2java.zip;

%CLASSPATH%

Also the path must setup to contain the DB2 libraries.
Start the "

Create DB2 Tables

" utility (

create.bat/create.sh

or 

START -

Programs - VSAM Redirector - Create DB2 Tables

). 

The tool prompts you for the following:

XML Filename

: enter the name of the XML File you exported in the last 

step (i.e. 

ffstores.xml

)

DB url

: enter a JDBC URL for your database, i.e.

jdbc:db2:sample

DB user: 

enter a user id you use for accessing the database

DB password: 

enter the users password

DB table name

: Enter the name of the data table, i.e.

FFSTORES

. This 

table will later contain the VSAM data.

Map table name:

Enter the name of the table that contains the mapping 

information, i.e. 

FFSTORES_MAP.

You can use the same map table for 

several clusters. 

Map name:

Enter the name of the map, i.e. 

FFSTORES.

This name is 

independent from the map defined with the VSE Navigator.

DB system

: Enter 

1 for DB/2

, 2 for Oracle.

The tool now imports the XML file and tries to connect to the database.

Next, the map info table is created (FFSTORES_MAP). Enter "Yes" to 

continue.

Then, the data table is created (FFSTORES). Enter "Yes" to continue.

Cluster Type

: Enter 1 (

KSDS without AIX

).

Primary key field: 

Enter the name of the key field: 

STOREID

. Press 

enter to create the table and indexes.

Redirect a VSAM file to DB2 

Содержание WAVV 2004

Страница 1: ...IBM IT Education Services 2004 IBM Corporation WAVV 2004 Setup of VSAM Redirector VSE Connectors Workshop...

Страница 2: ...Wilhelm Mild Ingo Franzki VSEESA de ibm com WAVV 2004 Connectors Setup of VSAM Redirector VSE Connectors Workshop Copyright IBM Corporation 2004...

Страница 3: ...le with a DB2 database running on a Windows By using the VSAM Redirector your existing VSAM programs doesn t require any revisions The VSAM Redirector makes use of a so called VSAM Data Access Exit VD...

Страница 4: ...VSAM INSERT requests to a HTML page on Windows This operation can be done with existing applications without changing touching them NOTE The VSAM Redirector Server does NOT require the VSE Connector C...

Страница 5: ...upport on the left side and then on e business connectors and utilities The page you see contains the VSAM Redirector Server and some tools that can be downloaded for free Navigate to the VSAM Redirec...

Страница 6: ...me Environment Standard Edition If the messages above are shown go to STEP1 4 STEP1 3 Install JDK if not on the system If following message is shown Java is not recognized as an internal or external c...

Страница 7: ...cify where to save the code Save it in a place you remember later on Download via FTP An alternative to the HTML download can be an FTP download if the code is on a FTP server For that issue commands...

Страница 8: ...Redirector Server The VSAM Redirector Server consists of ythe VSAM Redirector Server code ya detailed HTML documentation about the functions and possibilities ytwo sample handlers one for relational d...

Страница 9: ...ge will be opened STEP1 7 Start VSE Redirector server To start the VSAM Redirector Server execute run bat in the redirector directory or use START Programs VSAM Redirector Start Server Commands for Re...

Страница 10: ...dy defined map A map for a VSAM cluster can be defined with the Maptool VSE Navigator or IDCAMS RECMAP utility We work with the VSAM Cluster FLIGHT ORDERING ORDERS The ORDERS_MAP is already defined In...

Страница 11: ...s done to be able to build at the end one phase with the settings from all attendees Edit skeleton RDCFGxx Change the sample entry in the configuration as shown below Enter CASE M in the command line...

Страница 12: ...tor server console on Windows and press ENTER You must see the connection messages On VSE 1 You should see the preloaded records from VSAM file if OWNER VSAM 2 Make sure Ditto works in CHAR mode upper...

Страница 13: ...changes below in the source code it s in the last 3 rd firstname requestInfo getString 0 20 lastname requestInfo getString 20 20 flightnumber requestInfo getString 40 4 seats requestInfo getString 44...

Страница 14: ...SUN or IBM 9version 1 3 x or later http www ibm com developerworks java 9download VSAM Redirector Server http www 1 ibm com servers eserver zseries os vse support vseconn redir html 9install VSAM Red...

Страница 15: ...a database you must know the format of the records Therefore you must do a mapping containing all fields including their offset in the record length and type Start the VSE Navigator connect to the VSA...

Страница 16: ...PIC2 STRING 174 20 ACODE STRING 194 10 To verify the mapping use the VSE Navigator to display the VSAM data Right click on the map choose Display VSAM Data On the Display Filter dialog box press OK to...

Страница 17: ...ported in the last step i e ffstores xml DB url enter a JDBC URL for your database i e jdbc db2 sample DB user enter a user id you use for accessing the database DB password enter the users password D...

Страница 18: ...he configuration table Enter CASE M in the command line to switch to mixed case mode before editing IESRDENT CATALOG VSESP USER CATALOG X CLUSTER FFSTORES REPRO CLUSTER X EXIT IESREDIR X OWNER REDIREC...

Страница 19: ...COPYOUT FFSTORES REPRO CLUSTER VSAM CAT VSESPUC EXEC IDCAMS SIZE AUTO REPRO INFILE COPYIN OUTFILE COPYOUT NOREUSE EOJ During the copy process the VSAM Redirector Client will get control at open time...

Страница 20: ...FSTORES_MAP map FFSTORES X dbpassword password dbtable FFSTORES let the job load IESRDCFG into the SVA Step 2 let the job copy IESVEX01 to IKQVEX01 in PRD2 CONFIG Step 3 let the job load IKQVEX01 into...

Страница 21: ...om servers eserver zseries os vse pdf ieswue21 pdf ze business connectors tools z http www ibm com servers eserver zseries os vse ebus home html ze business Connectivity for VSE ESA SG24 5950 ze busin...

Отзывы: