BookmarkSubscribeRSS Feed
deleted_user
Not applicable
Hi all,

First of all, I am not a computer/SAS connoisseur.I have been using the SAS Date/Time converter for a while and it is great. The info is:http://www.softscapesolutions.com.au/date_converter.htm.
Yes I know I should write my code, but as I said I am not great doing so. Anyway, I use to have Vista (32 bits). I had the opportunity to change to to Windows 7 (64 bits) and now I cannot run the converter. I am not a savy SAS/computer user so I need help!!
I have been trying to use the proc cport as established in the SAS documentation. But that is more than my brain can handle. Ihave been spending the whole day (trial and error) and I am not getting anywhere.

I had the following code:

libname source 'c:\ssutil';
libname new 'c:\datec';
filename cportout 'c:\tranfile';
proc cport library=ssutil file=datec memtype=catalog;
run;

And the log file;
19 libname source 'c:\ssutil';
NOTE: Libname SOURCE refers to the same physical library as OLD.
NOTE: Libref SOURCE was successfully assigned as follows:
Engine: V9
Physical Name: c:\ssutil
20 libname new 'c:\datec';
NOTE: Libref NEW was successfully assigned as follows:
Engine: V9
Physical Name: c:\datec
21 filename cportout 'c:\tranfile';
22 proc cport library=ssutil file=datec memtype=catalog;
23 run;

WARNING: No logical assign for filename DATEC.
NOTE: The SAS System stopped processing this step because of errors.
NOTE: PROCEDURE CPORT used (Total process time):
real time 0.00 seconds
cpu time 0.00 seconds

HELP!!
8 REPLIES 8
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Your SAS log reveals this diagnostic:

WARNING: No logical assign for filename DATEC.


Your PROC CPORT invocation mentions file=datec so SAS is going to look for a "fileref" (an external allocadtion) not a "libref" (a SAS library/catalog allocation).

Scott Barry
SBBWorks, Inc.
deleted_user
Not applicable
Thanks! So I need to create a file ?
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
Pertinent SAS product DOC at link below:

http://support.sas.com/documentation/cdl/en/movefile/59598/HTML/default/a002575816.htm

Scott Barry
SBBWorks, Inc.


Suggested Google search, this topic / post:

proc cport file site:sas.com
deleted_user
Not applicable
Ok. I started form scratch. Download the library and following the instruction to assign the library.
My code is:

libname ssutil 'c:\ssutil';

%macro dc / cmd;
afa c=ssutil.dateconv.dateconv.frame;
%mend;

libname source 'ssutil';
filename cportout 'transport file';
proc cport library=source file=cportout memtype=catalog;
run;


And now the log shows:

69
70 libname ssutil 'c:\ssutil';
NOTE: Libref SSUTIL was successfully assigned as follows:
Engine: V9
Physical Name: c:\ssutil
71
72 %macro dc / cmd;
73 afa c=ssutil.dateconv.dateconv.frame;
74 %mend;
75
76 libname source 'ssutil';
NOTE: Library SOURCE does not exist.
77 filename cportout 'transport file';
78 proc cport library=source file=cportout memtype=catalog;
79 run;

ERROR: Library SOURCE does not exist.
NOTE: PROCEDURE CPORT used (Total process time):
real time 0.00 seconds
cpu time 0.00 seconds


What am I doing wrong?

Thank you for all your help... (I may need more)

M.
ArtC
Rhodochrosite | Level 12
you have again confused your library references. The LIBNAME statement assigns an alias, known as a libref, to a location. You reference the location C:\SSUTIL successfully - use that libref (ssutilx) in your PROC CPORT
[pre]
libname ssutilx 'c:\ssutil';
.... other stuff.....
proc cport library=ssutilx .......
[/pre]
I added an x to the libref to help distinguish the location from the libref. Message was edited by: ArtC
deleted_user
Not applicable
Thank you. I will try that now. I dropped my computer and it was being repaired it seems that I am not very lucky 😞
deleted_user
Not applicable
It is me again. This is my code:

libname ssutilx 'c:\ssutil';

%macro dc / cmd;
afa c=ssutil.dateconv.dateconv.frame;
%mend;

libname source 'ssutil';
filename cportout 'transport file';
proc cport library=ssutilx file=cportout memtype=catalog;
run;

An this is the output:

21 libname ssutilx 'c:\ssutil';
NOTE: Libname SSUTILX refers to the same physical library as SSUTIL.
NOTE: Libref SSUTILX was successfully assigned as follows:
Engine: V9
Physical Name: c:\ssutil
22
23 %macro dc / cmd;
24 afa c=ssutil.dateconv.dateconv.frame;
25 %mend;
26
27 libname source 'ssutil';
NOTE: Library SOURCE does not exist.
28 filename cportout 'transport file';
29 proc cport library=ssutilx file=cportout memtype=catalog;
30 run;

ERROR: File SSUTILX.DATECONV.CATALOG was created for a different operating system.
NOTE: PROCEDURE CPORT used (Total process time):
real time 0.00 seconds
cpu time 0.01 seconds

So it seems that I am back to square one. Pleas somebody help me!!
Ksharp
Super User
Hi.
First of all , the catalog you need to transport is generated by the Vista (32 bits) 's SAS ??
If so. try this.But I am not sure,I only success to transport SAS datasets from WindowsXP(32 bits) to AIX(64 bits) by using proc cport.

[pre]
libname source 'c:\ssutil';
filename cportout 'c:\tranfile';
proc cport library=source file=cportout memtype=catalog;
run;


After transport file 'tranfile' to the Windows 7 (64 bits) by using FTP or anyway you can.


filename tran 'c:\tranfile'; *suppose the file 'tranfile' is in your Windows 7 (64 bits) c:\;
proc import infile=tran library=work;
run;

SAS Innovate 2025: Register Now

Registration is now open for SAS Innovate 2025 , our biggest and most exciting global event of the year! Join us in Orlando, FL, May 6-9.
Sign up by Dec. 31 to get the 2024 rate of just $495.
Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

Find more tutorials on the SAS Users YouTube channel.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 8 replies
  • 1877 views
  • 0 likes
  • 4 in conversation