2 Installing Connect for SQL/XML
Before you start installation, verify that your system meets the specified requirements in Chapter 1 "Before You Install".
What Is Installed
The DataDirect Connect for SQL/XML installer installs the following components:
- Connect for SQL/XML JDBC driver (the SQL/XML JDBC driver) for processing SQL/XML queries.
- DataDirect Connect for SQL/XML online books are placed in the books directory in your Connect for SQL/XML installation directory.
- Online help for the DataDirect Query Builder for SQL/XML, Connect for JDBC drivers, and SequeLink JDBC driver is placed in the help directory in your Connect for SQL/XML installation directory.
See "About the Product Documentation" for details about the online books and online help.
Installing
NOTE: Make sure that your Java Virtual Machine in on your path. At a minimum, Connect for SQL/XML requires JDK 1.3.1; JDK 1.4 is required to use JDBC 3.0 features.
To install Connect for SQL/XML:
- If you are installing:
- From a CD, navigate to the sqlxml directory on the CD. Skip to Step 3.
- From the DataDirect Technologies Web site http://www.datadirect-technologies.com/download/
downloadindex.asp, download the cfsqlxml20download.jar file to an installer directory. This can also be the installation directory for Connect for SQL/XML, but does not have to be. You can choose another installation directory during the installation procedure. Continue with Step 2.- Switch to the installer directory, and use one of the following methods to extract the contents of the cfsqlxml20download.jar file:
- On Windows: Use the WinZip utility to open the cfsqlxml20download.jar file. Extract the contents of the jar file to the installer directory.
- On Windows or other operating systems: At a command prompt, change to the installer directory and unjar the contents of the jar file by entering the following command:
jar -xvf cfsqlxml20download.jar
Either method extracts the necessary files into the installer directory.
- To run the installer, follow either of the following procedures:
- If you prefer to use a Graphical User Interface (GUI), go to "GUI Installation" for instructions.
- If you prefer to use a command line, go to "Command-Line Installation" for instructions.
GUI Installation
- From the installer directory, enter the following command at a command prompt:
java -jar CfSQLXMLInstaller.jar
The DataDirect Connect for SQL/XML Installer window appears. Click Next to start the installation.
- The License Agreement window appears. Make sure that you read and understand the license agreement. To continue with the installation, select the I accept the terms in the license agreement option; then, click Next.
- The Product Licensing window appears.
Enter your product licensing information:
- If you are installing a licensed product, type the 8-character product key in the Enter Key field, and click the Add button. The appropriate database option appears in the Connect for SQL/XML with field.
If you were issued multiple product keys, you can add them sequentially. All database options listed in the Connect for SQL/XML with field are installed when you continue with the installation.
To delete a database option from the Connect for SQL/XML with field, select the option you want to delete, and click the Remove button. The option is removed from the field and is not installed when you continue with the installation.
- If you are installing an evaluation product, type
evalin the Enter Key field, and click the Add button. "Evaluation" appears in the Connect for SQL/XML with field.Click Next to continue with the installation.
- A window appears asking you to confirm the path to a JDK. This value is used during startup of the DataDirect Query Builder for SQL/XML. It also is used if you choose to compile the Connect for SQL/XML examples.
If a value does not appear in the Path to JDK field, the installer was unable to detect a required JDK. Type the path to a JDK, or click the Browse (...) button next to the field to browse to and select a JDK directory.
NOTE: This value must be a path to a JDK, not a JRE. At a minimum, Connect for SQL/XML requires JDK 1.3.1; JDK 1.4 is required to use JDBC 3.0 features.
Alternatively, you can configure the DataDirect Query Builder for SQL/XML startup file (as described in "Configuring the Builder Startup File") or the path environment variable file (as described in "Configuring the Path Environment Variable for Examples").
- A window appears allowing you to choose an installation directory. In the Install Directory field, type the path, including the drive letter on Windows machines, of the Connect for SQL/XML installation directory, or click the Browse (...) button next to the field to browse to and select an installation directory.
NOTE: The default value for the installation directory is the directory from which the installer is running. Verify that you have entered or selected the correct installation directory.
Then, click Next to continue.
- A window appears allowing you to confirm your installation options. Click Back to revise your choices, or click Install to continue with the installation. When you click Install, Connect for SQL/XML is installed.
- Click Finish to exit the Installer.
Command-Line Installation
- At a command prompt, enter the following command:
java -jar CfSQLXMLInstaller.jar -k key[,key]... [-h JDK_bin_dir] -d
install_dirwhere:
-kkey[,key]... Specifies your product licensing information, where key is the product key you received from DataDirect Technologies. If you were issued multiple product keys, you can enter them sequentially within the same command, separating the keys with a a comma(,). For example:-kkey1,key2,key3wherekey1is the first key,key2is a second key, andkey3is a third key, and so on.All database options associated with the entered keys are installed.If you want to install an evaluation copy of Connect for SQL/XML, entereval. For example:-k eval-hJDK_bin_dir Specifies the path to a required JDK, which is used to configure the startup file for the DataDirect Query Builder for SQL/XML. It also is used if you choose to compile the Connect for SQL/XML examples. This value must be a path to a JDK, not a JRE. At a minimum, Connect for SQL/XML requires JDK 1.3.1; JDK 1.4 is required to use JDBC 3.0 features.NOTE: If the directory path contains spaces, you must enclose the path name with double quotation marks, for example:This switch is optional.Alternatively, you can configure the DataDirect Query Builder for SQL/XML startup file (as described in "Configuring the Builder Startup File") or the path environment variable file (as described in "Configuring the Path Environment Variable for Examples").-dinstall_dir Specifies the full path, including the drive letter on Windows machines, to the Connect for SQL/XML installation directory.NOTE: If the directory path contains spaces, you must enclose the path name with double quotation marks, for example:- If Connect for SQL/XML was successfully installed, a message appears confirming the installation.
Example on Windows:
java -jar CfSQLXMLInstaller.jar -k key1,key2 -h C:\j2sdk1.4.1_02 -d "C:\Program Files\DataDirect\ Connect for SQLXML"This command-line example on Windows performs the following actions:
- Installs multiple database options for Connect for SQL/XML (
-kkey1,key2)- Specifies a path to a required JDK (
-h C:\j2sdk1.4.1_02).- Installs the preceding components to the installation directory C:\Program Files\DataDirect\Connect for SQLXML
(-d "C:\Program Files\DataDirect\Connect for SQLXML"). Note that because the directory path contains spaces, it is enclosed by quotation marks.Example on UNIX:
java -jar CfSQLXMLInstaller.jar -k key1 -h /home/user/ j2sdk1.4.1_02 -d /home/user/DataDirect/Connect_for_SQLXMLThis command-line example on UNIX performs the following actions:
- Installs only one database option for Connect for SQL/XML (
-kkey1). See the previous example for an example of how to specify multiple keys.- Specifies a path to a required JDK (
-h /home/user/j2sdk1.4.1_02).- Installs Connect for SQL/XML to the installation directory /home/user/DataDirect/Connect_for_SQLXML
(-d /home/user/DataDirect/Connect_for_SQLXML). Because the directory path does not contain spaces, it is not enclosed by quotation marks.Changing Your Installation
Once you have installed Connect for SQL/XML, you cannot use the standard installer to update or change your installation. If you want to add additional Connect for SQL/XML database options to your installation or update your evaluation Connect for SQL/XML to a standard licensed version after installation, you must use the License Tool.
To change your installation:
- From the installer directory, run the License Tool by specifying switches on a command line. You must specify values for all the switches. Use the following syntax:
java -jar CfSQLXMLLicenseTool.jar -k key[,key]... -d install_dir
- The installation is complete after running the License Tool.
Example on Windows:
This License Tool command-line example on Windows installs multiple database options for Connect for SQL/XML (
-kkey1,key2) to the installation directory C:\Program Files\DataDirect\Connect for SQLXML (-d "C:\Program Files\DataDirect\Connect for SQLXML"). Note that because the directory path contains spaces, it is enclosed by quotation marks.Example on UNIX:
This License Tool command-line example on UNIX installs only one database option for Connect for SQL/XML (
-kkey1) to the installation directory /home/user/DataDirect/Connect_for_SQLXML
(-d /home/user/DataDirect/Connect_for_SQLXML). See the previous example for an example of how to specify multiple keys. Because the directory path does not contain spaces, it is not enclosed by quotation marks.Testing the Connection to the Database
To test your connection to the database, you can use DataDirect Query Builder for SQL/XML, a tool for creating and modifying Connect for SQL/XML queries. You can create your own Connect for SQL/XML query for testing or use one of the example queries in the /examples directory in the Connect for SQL/XML installation directory. For instructions on using the DataDirect Query Builder for SQL/XML to connect to the database, refer to the DataDirect Connect for SQL/XML User's Guide.
Configuring Connect for SQL/XML
To compile and run Java applications that use Connect for SQL/XML queries (SQL/XML queries and jXTransformer queries) and jXTransformer write statements, you must add the following jar files to your path:
- Connect for JDBC driver jar files (db2.jar, informix.jar, oracle.jar, sqlserver.jar, sybase.jar, base.jar, and util.jar). You can find these files in the lib directory in the Connect for SQL/XML installation directory.
- SequeLink JDBC driver jar file (sljc.jar). You can find this file in the lib directory in the Connect for SQL/XML installation directory.
Configuring the Builder Startup File
During a normal installation, the installer configures the path to a JDK in the startup file for DataDirect Query Builder for SQL/XML. If the Connect for SQL/XML installer was unable to detect the path to a required JDK or you want to change the JDK to be used, you can configure the path to your JDK in the startup file located in the Connect for SQL/XML installation directory: builder.bat (Windows) or builder.sh (UNIX).
To configure the startup file:
- Using a text editor, open the appropriate file located in the Connect for SQL/XML installation directory.
- Remove the comment marker from the line for the PATH variable.
- On Windows: Change
rem set PATH=... toset PATH=...- On UNIX: Change
# PATH=... toPATH=...- Set the PATH variable so that it allows access to the JDK.
- On Windows: Change
PATH=<uncomment this line and fill in the path to your JDK installation>;%PATH%to the installation path for your JDK. For example:PATH=C:\JDK1_4\bin;%PATH%
- On UNIX: Change
PATH=<uncomment this line and fill in the path to your JDK installation>;$PATHto the installation path for your JDK. For example:PATH=/home/user1/JDK1_4/bin;$PATH
- Save the file, and use it to start the DataDirect Query Builder for SQL/XML.
Configuring the Path Environment Variable for Examples
During a normal installation, the installer configures the path to your JDK in the path environment variable file. The PATH environment variable is used to compile the Connect for SQL/XML examples. If the Connect for SQL/XML installer was unable to detect the path to a required JDK or you want to change the JDK to be used, you can configure the path to your JDK in the PATH environment variable file located in the examples directory in the Connect for SQL/XML installation directory: setenv.bat (Windows) or setenv.sh (UNIX).
To configure the path environment variable file:
- Using a text editor, open the appropriate file located in the examples directory in the Connect for SQL/XML installation directory.
- Remove the comment marker from the line for the PATH variable.
- On Windows: Change
rem set PATH=... toset PATH=...- On UNIX: Change
# PATH=... toPATH=...- Set the PATH variable so that it allows access to the JDK.
- On Windows: Change
PATH=<uncomment this line and fill in the path to your JDK installation>;%PATH%to the installation path for your JDK. For example:PATH=C:\JDK1_4\bin;%PATH%
- On UNIX: Change
PATH=<uncomment this line and fill in the path to your JDK installation>;$PATHto the installation path for your JDK. For example:PATH=/home/user1/JDK1_4/bin;$PATH
- Save the file. It will be used when you compile the Connect for SQL/XML examples.
Uninstalling
To uninstall Connect for SQL/XML, delete the entire Connect for SQL/XML installation directory.
For More Information
We recommend that you read the README text file that accompanies Connect for SQL/XML for current information regarding the release.