Hi Jade, I run this code to some data, it works. But for another data there is some error: 29 %let data=sas2012.elig14; 30 %let resized=sas2012.resize_elig14; 31 data size(keep=_name_ _length_); 32 set &data end=_eof; 33 array _c[*] _character_; 34 array _s[69] _temporary_; 35 do _i_ = 1 to dim(_c); 36 _s[_i_] = max(_s[_i_],length(_c[_i_])); 37 end; 38 if _eof then do _i_ = 1 to dim(_c); 39 length _name_ $32; 40 _name_ = vname(_c[_i_]); 41 _length_=_s[_i_]; 42 output; 43 end; 44 run; NOTE: There were 16747750 observations read from the data set SAS2012.ELIG14. NOTE: The data set WORK.SIZE has 51 observations and 2 variables. NOTE: DATA statement used (Total process time): real time 1:21.33 cpu time 1:21.23 45 proc print; 46 run; NOTE: There were 51 observations read from the data set WORK.SIZE. NOTE: PROCEDURE PRINT used (Total process time): 2 The SAS System 14:07 Thursday, January 14, 2021 real time 0.04 seconds cpu time 0.04 seconds 47 48 filename FT23F001 temp; 49 options missing=' '; 50 51 data _null_; 52 file FT23F001; 53 if 0 then set &data; 54 if _n_ eq 1 then do; 55 put 'Retain ' (_all_) (=) ';' @; 56 _file_ = translate(_file_,' ','='); 57 put; 58 end; 59 set size; 60 put 'Length ' _name_ '$' _length_ ';'; 61 run; NOTE: The file FT23F001 is: Filename=/apps/bitmp/SAS_work950000002AD8_lhnpbisasapro2.calpers.ca.gov/#LN00113, Owner Name=hli,Group Name=hli, Access Permission=-rw-rw----, Last Modified=15Jan2021:16:00:50 NOTE: 52 records were written to the file FT23F001. The minimum record length was 17. The maximum record length was 1205. NOTE: There were 51 observations read from the data set WORK.SIZE. NOTE: DATA statement used (Total process time): real time 0.01 seconds cpu time 0.00 seconds 62 63 /*Use the SOURCE2 Option with %include to Get a Detailed Log*/ 64 data &resized; 65 %include FT23F001 / source2; NOTE: %INCLUDE (level 1) file FT23F001 is file /apps/bitmp/SAS_work950000002AD8_lhnpbisasapro2.calpers.ca.gov/#LN00113. 66 +Retain MEMBER_KEY MEMBER_ID SUBSCRIBER_ID MEMBER_MONTH_START_DATE EFF_DATE TERM_DATE TIER GENDER AGE 66 !+AGE_BAND_NAME RELATION MEM_STAT MEMBER_MSA_NAME MEMBER_STATE MEMBER_ZIP PLAN_CODE Bargaining_Unit 66 !+Bargaining_Rank ORGANIZATION_CATEGORY ENROLLMENT_HEALTH_COVERAGE_TYPE PAY_OFFICE COBRA_INDICATOR PLAN_ROLLUP 66 !+REGION MEMBER_STATUS ELIGIBILITY_ZIP_CODE PLAN_TYPE PLAN_HEALTH_COVERAGE_TYPE STATE/PA_INDICATOR 66 !+CONTRACTING_REGION ENROLLMENT_COUNTY_CODE CALPERS_RELATION DIVISION_CALPERS_ID DXCG_MEDRX_SCORE 66 !+DXCG_MEDRX_SCORE_(FY) DXCG_RXONLY_SCORE DXCG_RXONLY_SCORE_(FY) DM_CONDITION DM_ACUITY MEMBER_RESIDENCE_COUNTY 66 !+MEMBER_RESIDENCE_MSA MEMBER_RESIDENCE_STATE MEMBER_RESIDENCE_ZIP MEMBER_EMPLOYER_COUNTY MEMBER_EMPLOYER_MSA 66 !+MEMBER_EMPLOYER_STATE MEMBER_EMPLOYER_ZIP IPA_ID IPA_NAME MM_UNITS PREMIUM_EMPLOYER_PAID PREMIUM_EMPLOYEE_PAID 66 !+ MARA_AGESEX_TOTAL_RISK MARA_CONC_TOTAL_RISK MARA_PROSP_TOTAL_RISK PAYER_LOB PAYER_TYPE GROUP_TYPE GRP_ID 66 !+GRP_NAME GRP_SIC GRP_SIC_DESC PCP_PROV_KEY PCP_ATTRIB_PROV_KEY INCURRED_YEAR PCP_PROV_GROUP_NAME 66 !+PCP_PROV_ATTRIB_GROUP_NAME MI_PCP24EM_PROV_GRP_NAME ; 22: LINE and COLUMN cannot be determined. NOTE 242-205: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred. ERROR 22-322: Syntax error, expecting one of the following: a name, a quoted string, a numeric constant, a datetime constant, a missing value, (, -, :, ;, _ALL_, _CHARACTER_, _CHAR_, _NUMERIC_. 200: LINE and COLUMN cannot be determined. NOTE: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred. ERROR 200-322: The symbol is not recognized and will be ignored. 3 The SAS System 14:07 Thursday, January 14, 2021 22: LINE and COLUMN cannot be determined. NOTE 242-205: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred. ERROR 22-322: Syntax error, expecting one of the following: a quoted string, a numeric constant, a datetime constant, a missing value, iterator, (. 202: LINE and COLUMN cannot be determined. NOTE: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred. ERROR 202-322: The option or parameter is not recognized and will be ignored. 22: LINE and COLUMN cannot be determined. NOTE 242-205: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred. ERROR 22-322: Syntax error, expecting one of the following: a quoted string, a numeric constant, a datetime constant, a missing value, iterator, (. 202: LINE and COLUMN cannot be determined. NOTE: NOSPOOL is on. Rerunning with OPTION SPOOL might allow recovery of the LINE and COLUMN where the error has occurred. ERROR 202-322: The option or parameter is not recognized and will be ignored. WARNING: The variables in the RETAIN statement have been partially initialized because of an insufficient number of elements in the constant list defined. WARNING: The variables in the RETAIN statement have been partially initialized because of an insufficient number of elements in the constant list defined. 67 +Length MEMBER_ID $49 ; 68 +Length SUBSCRIBER_ID $37 ; 69 +Length TIER $45 ; 70 +Length GENDER $1 ; 71 +Length AGE_BAND_NAME $5 ; 72 +Length RELATION $10 ; 73 +Length MEM_STAT $7 ; 74 +Length MEMBER_MSA_NAME $49 ; 75 +Length MEMBER_STATE $35 ; 76 +Length MEMBER_ZIP $5 ; 77 +Length PLAN_CODE $90 ; 78 +Length Bargaining_Unit $60 ; 79 +Length Bargaining_Rank $16 ; 80 +Length ORGANIZATION_CATEGORY $17 ; 81 +Length ENROLLMENT_HEALTH_COVERAGE_TYPE $26 ; 82 +Length PAY_OFFICE $35 ; 83 +Length COBRA_INDICATOR $16 ; 84 +Length PLAN_ROLLUP $23 ; 85 +Length REGION $14 ; 86 +Length MEMBER_STATUS $11 ; 87 +Length ELIGIBILITY_ZIP_CODE $5 ; 88 +Length PLAN_TYPE $7 ; 89 +Length PLAN_HEALTH_COVERAGE_TYPE $26 ; 90 +Length STATE/PA_INDICATOR $7 ; _ 391 200 76 ERROR 391-185: Expecting a variable length specification. ERROR 200-322: The symbol is not recognized and will be ignored. ERROR 76-322: Syntax error, statement will be ignored. 91 +Length CONTRACTING_REGION $14 ; 92 +Length ENROLLMENT_COUNTY_CODE $26 ; 93 +Length CALPERS_RELATION $27 ; 94 +Length DIVISION_CALPERS_ID $10 ; 95 +Length DM_CONDITION $20 ; 96 +Length DM_ACUITY $17 ; 4 The SAS System 14:07 Thursday, January 14, 2021 97 +Length MEMBER_RESIDENCE_COUNTY $26 ; 98 +Length MEMBER_RESIDENCE_MSA $50 ; 99 +Length MEMBER_RESIDENCE_STATE $7 ; 100 +Length MEMBER_RESIDENCE_ZIP $7 ; 101 +Length MEMBER_EMPLOYER_COUNTY $26 ; 102 +Length MEMBER_EMPLOYER_MSA $50 ; 103 +Length MEMBER_EMPLOYER_STATE $7 ; 104 +Length MEMBER_EMPLOYER_ZIP $7 ; 105 +Length IPA_ID $20 ; 106 +Length IPA_NAME $54 ; 107 +Length PAYER_LOB $10 ; 108 +Length PAYER_TYPE $27 ; 109 +Length GROUP_TYPE $11 ; 110 +Length GRP_ID $14 ; 111 +Length GRP_NAME $80 ; 112 +Length GRP_SIC $4 ; 113 +Length GRP_SIC_DESC $23 ; 114 +Length INCURRED_YEAR $4 ; 115 +Length PCP_PROV_GROUP_NAME $56 ; 116 +Length PCP_PROV_ATTRIB_GROUP_NAME $13 ; 117 +Length MI_PCP24EM_PROV_GRP_NAME $1 ; NOTE: %INCLUDE (level 1) ending. 118 set &data; 119 run; NOTE: The SAS System stopped processing this step because of errors. WARNING: The data set SAS2012.RESIZE_ELIG14 may be incomplete. When this step was stopped there were 0 observations and 72 variables. NOTE: DATA statement used (Total process time): real time 0.01 seconds cpu time 0.01 seconds Do you now how to solve it?
... View more