![](https://pdfstore-manualsonline.prod.a.ki/pdfasset/b/da/bda6fccb-b246-43e7-a520-a01ed647b8cf/bda6fccb-b246-43e7-a520-a01ed647b8cf-bgc8.png)
190 DBTYPE= Data Set Option Chapter 10
See Also
“DBSLICEPARM= LIBNAME Option” on page 95
DBTYPE= Data Set Option
Specifies a data type to use instead of the default DBMS data type when SAS creates a DBMS table
Valid in:
DATA and PROC steps (when accessing DBMS data using SAS/ACCESS
software)
DBMS support:
DB2 OS/390, DB2 UNIX/PC, Informix, ODBC, OLE DB, Oracle, Microsoft
SQL Server, SYBASE, Teradata
Default value:
DBMS-specific
Syntax
DBTYPE=(<column-name-1=<’>DBMS-type<’>>
<...<column-name-n=<’DBMS-type<’>>>)
Syntax Description
column-name
specifies a DBMS column name.
DBMS-type
specifies a DBMS data type. See the documentation for your SAS/ACCESS interface
for the default data types for your DBMS.
Details
By default, the SAS/ACCESS interface for your DBMS converts each SAS data type to a
predetermined DBMS data type when outputting data to your DBMS. When you need a
different data type, use DBTYPE= to override the default data type chosen by the
SAS/ACCESS engine.
Teradata Details: In Teradata, you can use DBTYPE= to specify data attributes for a
column. See your Teradata CREATE TABLE documentation for information on the data
type attributes that you can specify. If you specify DBNULL=NO for a column, do not
also use NOT NULL with DBTYPE= to specify this attribute for that column. If you do,
’NOT NULL’ is inserted twice in the column definition. This causes Teradata to
generate an error message.
Examples
In the following example, DBTYPE= specifies the data types that are used when you
create columns in the DBMS table.
data mydblib.newdept(dbtype=(deptno=’number(10,2)’ city=’char(25)’));
set mydblib.dept;