BookmarkSubscribeRSS Feed
MariaD
Barite | Level 11

Hi folks, 

 

We are currently working on a migration of our SAS servers. There is any way to estimate the total size needed to CPORT files? We did some test and in some case we have a compression of 70 or 80% of the original file.

 

 

Regards, 

4 REPLIES 4
Kurt_Bremser
Super User

I just ran this code on University Edition:

data myfold.class1;
set sashelp.class;
length longstr $100;
longstr = name;
do i = 1 to 10000;
  output;
end;
run;

data myfold.class2 (compress=yes);
set sashelp.class;
length longstr $100;
longstr = name;
do i = 1 to 10000;
  output;
end;
run;


proc cport data=myfold.class2 file='/folders/myfolders/class.cpr';
run;

class1.sas7bdat is 26.3 MB, class2.sas7bdat is 10.8 MB, class.cpr is 13.2 MB.

So it seems that the CPORT procedure does a compress, but not as good as the compress of the dataset. My tests also gave proof that CPORTing a compressed or uncompressed dataset will yield the same result.

Don't forget to use the compress=yes option when importing your CPORT files.

rabindrakumar
Fluorite | Level 6

Hi,

The mechanism of cport and compress is different, while using cport the file binaries are changed to be compatible according to cport zip functionality whereas compress is directly applied on dataset whitout changing the file binaries.

This is the reason cport has a bigger file size compared to compress.

Note:Beware of using cport, sometimes this procedure also corrupts the file.

Kurt_Bremser
Super User

@rabindrakumar wrote:

 

Note:Beware of using cport, sometimes this procedure also corrupts the file.


Can't second that, as I used CPORT/CIMPORT to move a whole data warehouse from mainframe to Reliant UNIX (SINIX) and later AIX without a hitch.

MariaD
Barite | Level 11

Thanks folks!

suga badge.PNGThe SAS Users Group for Administrators (SUGA) is open to all SAS administrators and architects who install, update, manage or maintain a SAS deployment. 

Join SUGA 

Get Started with SAS Information Catalog in SAS Viya

SAS technical trainer Erin Winters shows you how to explore assets, create new data discovery agents, schedule data discovery agents, and much more.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 1167 views
  • 1 like
  • 3 in conversation