BookmarkSubscribeRSS Feed
michellekwai
Obsidian | Level 7

Hi everyone, 

 

I'm a beginner in using sas viya and sas studio. I try to connect our netezza database with cas server and also load certain files from  netezza database to cas library. Codes are below, please feel free to point out how to correct it: 

 

cas;
caslib casbox datasource=(srctype="odbc",
username="123",
password="123",
odbc_dsn="Nz_Analysis",
catalog="*");

 

libname casbox cas;

 

proc casutil outcaslib="mycaslib";
load data=casbox.table_right replace;

list files incaslib="casbox";
run;

 

LOG:  only error is below: 

ERROR: File CASBOX.TABLE_RIGHT.DATA does not exist.
 
I understand the casbox doesn't have any files in it. but how can I load files in it.... I'm confused by those codes.. 
 
Thanks in advance! I appreciate for all the helps! 
 
Regards, 
Michelle 
4 REPLIES 4
alexal
SAS Employee

@michellekwai,

 

Could you please show us full SAS log?

michellekwai
Obsidian | Level 7

Hi @alexal

Actually the problem is below. I tried several days to figure out how to do that..... 

 

I come across a problem:  load files in the memory.

 

But I can connect to our odbc database successfully and I can see all files in caslib casbox too. Code below:

 

cas;
caslib casbox datasource=(srctype="odbc",
username="123",
password="123",
odbc_dsn="Nz_Analysis",
catalog="*");


proc casutil ;
list files incaslib="casbox";

load casdata="CUN1"  casout="CUN1";
run;
quit;

 

ERROR: ERROR: ERROR: relation does not exist ANALYSIS.123.CUN1
ERROR: Function failed.
ERROR: The action stopped due to errors.
 
Any ideas to solve this problem? Thanks in advance! !
 
Regards, 
Michelle 
michellekwai
Obsidian | Level 7

Hi @alexal

The whole log is below: 

 

SAS Studio

1 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
72
73 /* CASLIB for SANDBOX */
74 cas;
NOTE: The session CASAUTO connected successfully to Cloud Analytic Services vjxnsvcasp01.local using port 5570. The UUID
is 1ef82d33-901e-e44f-b111-d732e356308f. The user is 123 and the active caslib is CASUSERHDFS(123).
NOTE: The SAS option SESSREF was updated with the value CASAUTO.
NOTE: The SAS macro _SESSREF_ was updated with the value CASAUTO.
NOTE: The session is using 6 workers.
75 caslib tlake datasource=(srctype="odbc",
76 username="123",
77 password=XXXXXXXXXXXXXX,
78 odbc_dsn="Nz_Analysis",
79 catalog="*");
NOTE: 'TLAKE' is now the active caslib.
NOTE: Cloud Analytic Services added the caslib 'casbox'.
NOTE: Action to ADD caslib casbox completed for session CASAUTO.
80
81 proc casutil ;
NOTE: The UUID '1ef82d33-901e-e44f-b111-d732e356308f' is connected using session CASAUTO.
82 load casdata="CUN1" casout="CUN1";
NOTE: Performing serial LoadTable action using SAS Data Connector to ODBC.
ERROR: ERROR: ERROR: relation does not exist TRUSTMARK_ANALYSIS.B513SASP.CUN1
ERROR: Function failed.
ERROR: The action stopped due to errors.
NOTE: The Cloud Analytic Services server processed the request in 0.242575 seconds.
83 run;
 
84
85 OPTIONS NONOTES NOSTIMER NOSOURCE NOSYNTAXCHECK;
98
alexal
SAS Employee

@michellekwai,


I would suggest you open a track with our access team.

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 4 replies
  • 1900 views
  • 0 likes
  • 2 in conversation