Contents SAS/SHARE Driver 9.1.3 for JDBC Previous Next

SAS/SHARE® Driver for JDBC Specifics

The SAS/SHARE driver for JDBC complies with version 2.0 of the Java Database Connectivity (JDBC) API specification from Sun Microsystems. However, some features such as record-level locking and scrolling are not supported with SAS software. The remainder of this page discusses other details about our implementation of the JDBC specification.

Connecting to a Database

The getConnection methods in the JDBC DriverManager establish a connection to a database. Connection arguments can be specified in either a URL or a java.util.Properties object.

Note: If you specify the connection arguments in both the java.util.Properties object and the URL, the values in the URL will take precedence.

The URL must be of the form:

  jdbc:sharenet://hostname:portnumber<?property-1=value-1<...&property-n=value-n>>

where

hostname
specifies the name of the machine where the SAS/SHARE server is running
portnumber
specifies the port the SAS/SHARE server is configured to use
property/value pairs
specifies the connection properties and their values

You can specify the following properties as connection arguments:

shareUser
A valid user name for the SAS/SHARE server you specify in the URL.

sharePassword
The password that corresponds to the username you specify with the shareUser property.

appname
The name of the applet or application you're creating. This name will appear in the all server log entries related to the program. It is limited to eight characters; names longer than eight characters will be truncated.

sapw
The access password for the SAS/SHARE server your program will connect to.

pt2dbpw
The SQL Pass-Through access password for the SAS/SHARE server your program will connect to. SQL Pass-Through access permits you program to access external database management systems (DBMS).

librefs
A list of libnames and corresponding paths that specify the location of each data set your program will access. The librefs property value must be specifies as follows:
     (libname 'filepath'; libname 'filepath';...)

dbms
The name of the DBMS your program will access; the value must be eight characters padded with blanks. The default is "SQLVIEW ", which specifies that SAS data sets will be accessed. If you are not accessing SAS data, specify the name of the foreign DBMS as it is defined using SAS/ACCESS software.

dbms_options
Options for the foreign DBMS your program will access. Specify the options as you specify the database-definition arguments when using the PROC SQL statement CONNECT TO.

remarks
A Boolean value that determines whether the SAS/SHARE driver for JDBC returns the data set label for each data set in the library that your program accesses. If the value is True, the labels are returned; the default value is False.

Note: When this property is set to True, any operation that involves reading and returning data set labels can result in poor performance because each data set must be opened in order to read the label. For example, if this property is set to True, performance may be degraded when using the ShareNetDatabaseMetaData.getTables() method to retrieve a description of the tables in a catalog.

undoPolicyNone
A Boolean value that determines whether changes to the data are undone when an UPDATE or INSERT statement generates errors. When the value is set to True (the recommended setting), the changes are not undone; when the value is set to False, the server attempts to undo the changes.

routerUrl
The URL of the Message Router. The routerUrl property value must be specifies as follows:
     (routerUrl http://your_server/cgi-bin/shrcgi)

where http://your_server/cgi-bin/shrcgi is the URL of the Message Router (shrcgi or shrcgi.exe), one of the tunnel feature's server programs.

Feature Support Details

This section discusses the support that the SAS/SHARE driver for JDBC provides for various common DBMS features. It also lists the SQL data types and table types that are supported.

Stored Procedures

SAS software does not support stored procedures. While we provide the class ShareNetCallableStatement, none of its methods are supported.

Foreign DBMS Metadata

When the ShareNetConnection class establishes a connection with a SAS/SHARE server, it creates a ShareNetDatabaseMetaData object for SAS data sets only. If your program connects to a foreign DBMS, no metadata will be returned.

SQL Catalogs

SAS software does not support SQL catalogs. Parameter input that specifies SQL catalog information to SAS/SHARE driver for JDBC methods is ignored.

Supported SQL Data Types

The following list identifies the SQL data types that are supported by the SAS/SHARE driver for JDBC:

Supported Table Types

The SAS/SHARE driver for JDBC supports tables of the following types:


Contents SAS/SHARE Driver 9.1.3 for JDBC Previous Next