Previous Page | Next Page

SAS/ACCESS Interface to Aster nCluster

LIBNAME Statement Specifics for Aster nCluster


Overview

This section describes the LIBNAME statement options that SAS/ACCESS Interface to Aster nCluster supports and includes examples. For details about this feature see Overview of the LIBNAME Statement for Relational Databases.

Here is the LIBNAME statement syntax for accessing Aster nCluster.

LIBNAME libref aster <connection-options> <LIBNAME-options>;

Arguments

libref

specifies any SAS name that serves as an alias to associate SAS with a database, schema, server, or group of tables and views.

aster

specifies the SAS/ACCESS engine name for the Aster nCluster interface.

connection-options

provide connection information and control how SAS manages the timing and concurrence of the connection to the DBMS. When you use the LIBNAME statement, you can connect to the Aster nCluster database in two ways. Specify only one of these methods for each connection because they are mutually exclusive.

  • SERVER=, DATABASE=, PORT=, USER=, PASSWORD=

  • DSN=, USER=, PORT=

  • NOPROMPT=

  • PROMPT=

  • REQUIRED=

Here is how these options are defined.

SERVER=<'>server-name<'>

specifies the host name or IP address where the Aster nCluster database is running. If the server name contains spaces or nonalphanumeric characters, you must enclose it in quotation marks.

DATABASE=<'>database-name<'>

specifies the Aster nCluster database that contains the tables and views that you want to access. If the database name contains spaces or nonalphanumeric characters, you must enclose it in quotation marks. You can also specify DATABASE= with the DB= alias.

PORT=port

specifies the port number that is used to connect to the specified Aster nCluster database. If you do not specify a port, the default port 5480 is used.

USER=<'>Aster nCluster user-name<'>

specifies the Aster nCluster user name (also called the user ID) that you use to connect to your database. If the user name contains spaces or nonalphanumeric characters, you must enclose it in quotation marks.

PASSWORD=<'>Aster nCluster password<'>

specifies the password that is associated with your Aster nCluster User ID. If the password contains spaces or nonalphanumeric characters, you must enclose it in quotation marks. You can also specify PASSWORD= with the PWD=, PASS=, and PW= aliases.

DSN=<'>Astern Cluster data-source<'>

specifies connection options for your data source or database. Separate multiple options with a semicolon. If you do not specify enough correct connection options, an error is returned. No dialog box displays to help you complete the connection string.

NOPROMPT=<'>Astern Cluster ODBC-connection-options<'>

specifies connection options for your data source or database. Separate multiple options with a semicolon. If you do not specify enough correct connection options, an error is returned. No dialog box displays to help you with the connection string.

PROMPT=<'> Astern Cluster ODBC-connection-options<'>

specifies connection options for your data source or database. Separate multiple options with a semicolon. When connection succeeds, the complete connection string is returned in the SYSDBMSG macro variable. PROMPT= does not immediately try to connect to the DBMS. Instead, it displays a dialog box that contains the values that you entered in the PROMPT= connection string. You can edit values or enter additional values in any field before you connect to the data source. This option is not supported on UNIX platforms.

REQUIRED=<'>Aster nCluster ODBC-connection-options<'>

specifies connection options for your data source or database. Separate multiple options with a semicolon. When connection succeeds, the complete connection string is returned in the SYSDBMSG macro variable. If you do not specify enough correct connection options, a dialog box prompts you for the connection options. REQUIRED= lets you modify only required fields in the dialog box. This option is not supported on UNIX platforms.

LIBNAME -options

define how SAS processes DBMS objects. Some LIBNAME options can enhance performance, while others determine locking or naming behavior. The following table describes the LIBNAME options for SAS/ACCESS Interface to Aster nCluster with the applicable default values. For more detail about these options, see LIBNAME Options for Relational Databases.

SAS/ACCESS LIBNAME Options for Aster nCluster
Option Default Value
ACCESS=
none
AUTHDOMAIN=
none
AUTOCOMMIT=
operation-specific
CONNECTION=
UNIQUE
CONNECTION_GROUP=
none
DBCOMMIT=
1000 (inserting) or 0 (updating)
DBCONINIT=
none
DBCONTERM=
none
DBCREATE_TABLE_OPTS=
none
DBGEN_NAME=
DBMS
DBINDEX=
YES
DBLIBINIT=
none
DBLIBTERM=
none
DBMAX_TEXT=
1024
DBMSTEMP=
NO
DBNULLKEYS=
YES
DBPROMPT=
NO
DBSASLABEL=
COMPAT
DEFER=
NO
DELETE_MULT_ROWS=
NO
DIMENSION=
NO
DIRECT_EXE=
none
DIRECT_SQL=
YES
IGNORE_ READ_ONLY_COLUMNS=
NO
INSERTBUFF=
automatically calculated based on row length
LOGIN_TIMEOUT=
0
MULTI_DATASRC_OPT=
none
PARTITION_KEY=
none
PRESERVE_COL_NAMES=
see Naming Conventions for Aster nCluster
PRESERVE_TAB_NAMES=
see Naming Conventions for Aster nCluster
QUERY_TIMEOUT=
0
QUOTE_CHAR=
none
READBUFF=
automatically calculated based on row length
REREAD_EXPOSURE=
NO
SCHEMA=
none
SPOOL=
YES
SQL_FUNCTIONS=
none
SQL_FUNCTIONS_COPY=
none
STRINGDATES=
NO
TRACE=
NO
TRACEFILE=
none
UPDATE_MULT_ROWS=
NO
USE_ODBC_CL=
NO
UTILCONN_TRANSIENT=
NO


Aster nCluster LIBNAME Statement Examples

In this example, SERVER=, DATABASE=, USER=, and PASSWORD= are the connection options.

LIBNAME mydblib ASTER SERVER=npssrv1 DATABASE=test
     USER=netusr1 PASSWORD=netpwd1;

PROC Print DATA=mydblib.customers;
     WHERE state='CA';
run;

In this next example, the DSN= option, the USER= option, and the PASSWORD= option are connection options. The Aster nCluster data source is configured in the ODBC Administrator Control Panel on Windows platforms. It is also configured in the odbc.ini file or a similarly named configuration file on UNIX platforms.

LIBNAME mydblib aster dsn=nCluster user=netusr1 password=netpwd1;

PROC Print DATA=mydblib.customers;
     WHERE state='CA';
run;

Here is how you can use the NOPROMPT= option.

libname x aster NOPROMPT="dsn=aster;";
libname x aster NOPROMPT="DRIVER=nCluster; server=192.168.28.100;
   uid=username; pwd=password; database=asterdb";

This example uses the PROMPT= option. Blanks are also passed down as part of the connection options. So the specified value must immediately follow the semicolon.

libname x aster PROMPT="DRIVER=nCluster;";

The REQUIRED= option is used in this example. If you enter all needed connection options, REQUIRED= does not prompt you for any input.

libname x aster REQUIRED="DRIVER=nCluster; server=192.168.28.100;
   uid=username;pwd=password; database=asterdb ;";

This error results because the database was specified as asterdb, which contains a trailing blank, instead of asterdb.

ERROR: CLI error trying to establish connection: 
     ERROR:  Database asterdb  does not exist.

Previous Page | Next Page | Top of Page