BookmarkSubscribeRSS Feed

[SAS 활용 FAQ] SAS dataset을 읽어 Oracle에 table을 생성할 때, 숫자 column 의 속성을 변경하고 싶은데 어떻게 하면 될까요?

Started ‎10-06-2021 by
Modified ‎10-06-2021 by
Views 273

SAS Dataset을 Oracle에 load하려 합니다. 기본적으로 저희 Oracle db에서 관리하는 숫자의 기본 Format은 NUMBER입니다. 그런데, 숫자로 지정된 값을 Oracle로 load해서 Column type을 확인 하면 "BINARY_DOULBE"로 생성이 됩니다.

 

저희가 원하는 건 OracleTable 생성 시, 숫자 Column NUMBER Type으로 생성되는 것인데, 숫자에 대한 SAS 컬럼정보를 NUMBER Type으로 변경하는 방법을 알고 싶습니다.

 

[답변]

아래 link의 예시와 같이 “DBTYPE=” 옵션을 사용해  보시기 바랍니다. https://support.sas.com/techsup/notes/v8/4/961.html

 

libname mylib odbc dsn=xxx uid=xxx pwd=xxx preserve_tab_names=yes;

data mylib.dept(dbtype=(sas_var=’NUMBER’));

set sasuser.old;

run;

Version history
Last update:
‎10-06-2021 10:59 PM
Updated by:
Contributors

hackathon24-white-horiz.png

The 2025 SAS Hackathon Kicks Off on June 11!

Watch the live Hackathon Kickoff to get all the essential information about the SAS Hackathon—including how to join, how to participate, and expert tips for success.

YouTube LinkedIn

Article Labels
Article Tags