Problem Note 69759: The SAS DATE and DATETIME formats are converted to the BEST format when you save a SAS® Cloud Analytic Services table to a Parquet file
When you save a SAS® Cloud Analytic Services (CAS) table that contains a DATE or DATETIME format to a Parquet file, the format is lost and converted to the BEST format in the resulting Parquet data.
For example, if you run code similar to the following, you encounter this issue:
CAS mysess SESSOPTS=(CASLIB=casuser TIMEOUT=99 LOCALE="en_US" metrics=true);
caslib _ALL_ assign;
data casuser.TEST_DATE ;
format MADATE ddmmyy10. ;
format MADATETIME datetime16. ;
MADATE = date() ;
MADATETIME = datetime() ;
run ;
proc casutil incaslib=casuser outcaslib=casuser ;
save casdata="TEST_DATE" casout="TEST_DATE.parquet" replace ;
run ;
proc casutil incaslib=casuser outcaslib=casuser ;
load casdata="TEST_DATE.parquet" casout="TEST2";
run ;
proc cas;
setsessopt / caslib="casuser" ;run;
columninfo / table={name="TEST2",caslib="casuser"};
run;
As a result, the incorrect BEST format for the MADATE and MADATETIME columns is reported in the following SAS log:
Results from table.columnInfo
Column Information for TEST2 in Caslib CASUSER(xyz)
Formatted Format Format
Column Id Type Length Length Format Width Decimal
MADATE 1 double 8 12 BEST 12 0
MADATETIME 2 double 8 12 BEST 12 0
Click the Hot Fix tab in this note for a link to instructions about accessing and applying the software update.
Operating System and Release Information
SAS System | SAS Viya | Linux for x64 | 3.5 | Stable 2022.10 | Viya | Viya |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
Type: | Problem Note |
Priority: | high |
Date Modified: | 2022-12-14 15:23:41 |
Date Created: | 2022-12-13 09:31:42 |