/* Méthode standard - ne permet pas l'optimisation DVR directe */
proc casutil;
load data=maTableWork casout="maTableCAS";
quit;
1
/* Méthode standard - ne permet pas l'optimisation DVR directe */
2
PROC CASUTIL;
3
load DATA=maTableWork casout="maTableCAS";
4
QUIT;
The problem is that the LOAD DATA statement of PROC CASUTIL does not offer a native option to define the deafaultmemoryFormat. Therefore, the table is loaded with the default format, consuming more memory than necessary.
The False Good Idea: Two-Step Loading
Faced with this limitation, a commonly attempted workaround consists of:
Loading the table normally (standard format).
Using the table.copyTable action to create a compressed copy in DVR.
Deleting the original table.
While functional, this method is inefficient ("clunky"). It temporarily doubles memory usage and unnecessarily increases I/O.
The Optimal Solution: The UPLOAD Statement in PROC CAS
The varcharConversion option is an ideal complement to DVR. While DVR compresses repeated values, switching to the VARCHAR type reduces the space allocated to variable-length character strings, thus maximizing storage efficiency.
The codes and examples provided on WeAreCAS.eu are for educational purposes. It is imperative not to blindly copy-paste them into your production environments. The best approach is to understand the logic before applying it. We strongly recommend testing these scripts in a test environment (Sandbox/Dev). WeAreCAS accepts no responsibility for any impact or data loss on your systems.
SAS and all other SAS Institute Inc. product or service names are registered trademarks or trademarks of SAS Institute Inc. in the USA and other countries. ® indicates USA registration. WeAreCAS is an independent community site and is not affiliated with SAS Institute Inc.
This site uses technical and analytical cookies to improve your experience.
Read more.