13.07.2015 Views

SAS/ACCESS 9.2 for Relational Databases: Reference, Fourth Edition

SAS/ACCESS 9.2 for Relational Databases: Reference, Fourth Edition

SAS/ACCESS 9.2 for Relational Databases: Reference, Fourth Edition

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>SAS</strong>/<strong>ACCESS</strong> Interface to ODBC 4 ODBC Concepts 655source name (DSN) by selecting a particular ODBC driver <strong>for</strong> the database with whichyou want to work from the list of available drivers. You can then provide specificconnection in<strong>for</strong>mation <strong>for</strong> the database that the specific driver can access.USER DSNSYSTEM DSNspecific to an individual user. It is available only to the user whocreates it.not specific to an individual user. Anyone with permission to accessthe data source can use it.FILE DSN not specific to an individual user. It can be shared among users eventhough it is created locally. Because this DSN is file-based, itcontains all in<strong>for</strong>mation that is required to connect to a data source.You can create multiple DSNs in this way and then reference them in your PC-based<strong>SAS</strong>/<strong>ACCESS</strong> Interface to ODBC code.When you use the ODBC Data Source Administrator on the PC to create your ODBCdata sources, the ODBC drivers <strong>for</strong> the particular databases from which you want toenable access to data are often in the list of available drivers, especially those <strong>for</strong> themore common databases. If the ODBC driver you want is not listed, you must work toobtain one.ODBC on a UNIX Plat<strong>for</strong>mODBC on UNIX works a bit differently. The ODBC driver manager and ODBCdrivers on the PC are available by default, so you need only plug them in. Becausethese components are not generally available on UNIX, you must instead work withthird-party vendors to obtain them.When you submit <strong>SAS</strong>/<strong>ACCESS</strong> Interface to ODBC code, <strong>SAS</strong> looks first <strong>for</strong> anODBC driver manager. It checks the directories that are listed in such environmentvariables settings as LD_LIBRARY_PATH, LIBPATH, or SHLIB_PATH, depending onyour UNIX plat<strong>for</strong>m. It uses the first ODBC driver manager that it finds.The ODBC driver manager then checks .INI files—either a stand-alone ODBC.INIfile, or a combination of ODBC.INI and ODBCINST.INI files—<strong>for</strong> the DSNs that youspecified in your code. To make sure that the intended .INI files are referenced, you canuse such environment variables settings as ODBCINI or ODBCSYSINI, depending onhow your .INI files are set up. You can set up global .INI files <strong>for</strong> all your users, or youcan set up .INI files <strong>for</strong> single users or groups of users. This is similar to using theODBC Data Source Administrator to create either SYSTEM or USER DSNs <strong>for</strong> PCplat<strong>for</strong>ms. One or more .INI files include a section <strong>for</strong> each DSN, and each sectionincludes specific connection in<strong>for</strong>mation <strong>for</strong> each data source from which you ultimatelywant to enable access to data. Some ODBC driver vendors provide tools with which youcan build one or more of your .INI files. However, editing a sample generic .INI file thatis provided with the ODBC driver is often done manually.Most database vendors—such as Sybase, Oracle, or DB2—include ODBC drivers <strong>for</strong>UNIX plat<strong>for</strong>ms. However, to use <strong>SAS</strong>/<strong>ACCESS</strong> Interface to ODBC, you must pair aUNIX-based ODBC driver manager with your UNIX-based ODBC driver. FreewareODBC driver managers <strong>for</strong> UNIX such as unixODBC are generally available <strong>for</strong>download. Another alternative is to obtain the required ODBC client components <strong>for</strong>UNIX plat<strong>for</strong>ms from third-party vendors who market both ODBC drivers <strong>for</strong> variousdatabases and an ODBC driver manager that works with these drivers. To use<strong>SAS</strong>/<strong>ACCESS</strong> Interface to ODBC, you can select any ODBC client solution that youwant as long as it is ODBC-compliant.ODBC <strong>for</strong> PC and UNIX Plat<strong>for</strong>msThese concepts are common across both PC and UNIX plat<strong>for</strong>ms.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!