Overview of database access
Host On-Demand includes three paths for database access:
-
Access through a Host On-Demand display emulation session
The functionality of the Database On-Demand client is now also integrated
into the following types of Host On-Demand display emulation sessions:
3270 Display sessions, 5250 Display sessions, and VT Display sessions.
The SQL Wizard and the File Upload Wizard,
which were formerly available only in the Database On-Demand client,
are now also accessible through these display emulation sessions.
The following entries are included in the Actions menu of the session window:
-
Actions > Transfer Data > Send Data to Host
Allows the user to manage and run File Update statements.
See Send Data to Host.
-
Actions > Transfer Data > Receive Data from Host
Allows the user to manage and run SQL statements.
See Receive Data from Host.
-
Actions > Data Transfer Defaults
Allows the user to set Default values for some
input fields in the SQL Wizard and the File Upload Wizard.
See Data Transfer Defaults.
-
Access through macros
The SQLQuery action allows the macro writer to send an SQL query
to a database server, retrieve the data resulting
from the query, and then either write the data
into a global variable, write the data into a file,
or display the data.
See SQLQuery action (<sqlquery> element) in the Macro Programming Guide.
The File Upload action allows the macro writer to send
a File Upload command to a database server
to create, append data to, replace, or update a host database.
See FileUpload action (<fileupload> element) in the Macro Programming Guide.
-
Access through the Database On-Demand Applet
The Database On-Demand applet is available only in the
Configuration server-based client model.
The applet includes text and graphical interfaces for building and running SQL statements and File Upload statements.
See Getting started with Database On-Demand.
With all three paths of database access, users can
perform the following actions:
-
Connect to a remote database server on a host other than
the one to which the session is connected.
-
For example, if a user is running a 3270 Display session
that is connected to a zSeries host,
the user can also access a remote database server
running on an iSeries host.
-
This capability does not apply to the Database On-Demand client,
which connects directly to a remote database server.
- Use the SQL Wizard's graphical user interface to build complex SQL statements, or type
in or paste SQL statements directly into an input field.
- Build and run the following types of database statements:
- SQL Select, Insert, Update, and Delete statements.
- File Upload Create, Replace, Append, and Update statements.
-
Retrieve, display, and save the results of SQL Select statements.
Results can be saved in the following file formats:
-
ASCII Text (*.txt)
-
Comma-separated values (*.csv)
-
Lotus 1-2-3 (*.wk1)
-
Microsoft Excel - BIFF3 (*.xls)
-
Microsoft Excel - BIFF4 (*.xls)
-
HTML (*.html)
-
XML (*.xml)
-
Upload the contents of files in the following file formats:
-
ASCII Text (*.txt)
-
Comma-separated values (*.csv)
-
Lotus 1-2-3 (*.wk1)
-
Microsoft Excel - BIFF3 (*.xls)
-
Microsoft Excel - BIFF4 (*.xls)
-
XML (*.xml)
- Save and reuse SQL statements and File Upload statements.
A Java Database Connectivity (JDBC) driver must be
installed on the client workstation.
The JDBC driver for an iSeries host (AS/400 Toolbox for Java) is included with Host On-Demand
and is automatically downloaded to the client.
|
If you use a proxy server to connect to an iSeries and you
use the Download client,
you can decrease the download time when loading the Database On-Demand applet.
Edit the CommonJars.js file and replace hoddba.jar with hodpxdba.jar.
This smaller jar file contains only the classes needed for running Database On-Demand when connecting through a proxy server.
|
Example uses of database access
- Dynamic queries
-
Without knowing SQL, a user can use the SQL Wizard to create an SQL statement or
to modify an existing SQL statement. The statement can then be executed or
saved for later use.
-
Saved SQL and File Upload statements
-
Saved SQL and File Upload statements can be distributed to a user or a group of users.
The user can then select the saved SQL or File Upload statement
and click Run to view the results.
-
File download
-
Query results can be saved in various file formats and later imported into
a personal productivity program, such as a spreadsheet or a word processor.
-
File upload
-
The contents of database files in various formats can be stored into a host database.
-
Web page publishing
-
For the Database On-Demand client, results can be written to an HTML template file.
An HTML template file is an HTML document that contains special tags indicating where the query
results should be imbedded. The resulting Web page contains everything in the
template file, including the query results in the specified location.
-
Security
-
Applets running under browsers have limited access to system resources,
such as local file access and network access.
The Host On-Demand client and Database On-Demand client
request special permissions from the browser to perform these
operations. Browsers display a window asking the user to grant
or deny these requests. If the user denies the request, the
applet is not granted the privilege, and the operation fails.
Related topics