Hi SAS Community,
I'm reaching out for some guidance on loading large .dat files into SAS Viya 4.
Our Process: Each semester, we generate census datasets from snapshots of data received as .dat files from IT. Previously, we used Base SAS programs to read these files from a Windows file server and convert them to SAS datasets.
Challenge: Since transitioning to SAS Viya 4, I'm encountering difficulties loading the .dat files, particularly with larger ones exceeding 100MB. I'm unable to load or copy them directly into SAS Viya.
Clarification: I'm copying the .dat files to "SAS Content," not the CAS server (I am unable to copy to cas). For this project my programs typically read data from the "SAS Content" location.
Specific Issue: Out of 19 .dat files, 17 successfully copy to the "SAS Content" path and able to convert them into sas datasets. However, the two remaining files (119MB and 153MB) fail to copy, resulting in an error (details provided below).
I'd greatly appreciate any insights or suggestions on how to approach loading/copying these large .dat files into SAS Viya 4. Any advice on alternative methods or configuration adjustments would be incredibly helpful.
Thank you for your time and support!
Sincerely,
Bhaskar
... View more
Obs months 1 2 2 2 3 6 4 2 I want to merge the dataset above with other datasets based on value of months variable. For example, I want to merge two months of data for the first record, two months of data for the second record, 6 months of data for the third record, and 2 months of records for the fourth record. Is there a systematic way of doing it? I was thinking about creating a variable based on the months variable and create a loop within a macro to achieve it.
... View more
Hello, I was wondering if there was a way to check a range of variables to see if any are equal to a certain value.
data checks;
input check_1 $ check_2 $ check_3 $ check_4 $;
datalines;
Checked Unchecked Unchecked Unchecked
Unchecked Unchecked Unchecked Unchecked
Unchecked Checked Unchecked Unchecked
;
run;
Like for the above code, is there a way for me to test each line, and if any of the check_# variables equal to 'Checked' and save it to a new variable?
Thank you!
... View more
I extracted some code(from SAS communities) to calculate the nth business day of the month. It is a little off. I was testing the code to make sure it returned the 3rd day of the month. I noticed Jul ,Aug, and Oct were giving me the 4th day instead. All these months have 31 days so wondering if that is the reason. I want the 3 day of the month and will adjust for holidays for Jan, Jul and Sept only when it falls on a weekend. Can anyone confirm what is happening in these months and maybe how to accommodate the 1 day difference. Does SAS have a US holilday calendar? data test; format business_day1 business_day2 business_day3 business_day4 business_day5 date9.; business_day1 = intnx('weekday', intnx('month', '23jun2024'd, 0, 'b'), 3); business_day2 = intnx('weekday', intnx('month', '18jul2024'd, 0, 'b'), 3); business_day3 = intnx('weekday', intnx('month', '06aug2024'd, 0, 'b'), 3); business_day4 = intnx('weekday', intnx('month', '11sep2024'd, 0, 'b'), 3); business_day5 = intnx('weekday', intnx('month', '25oct2024'd, 0, 'b'), 3); run;
... View more
Hello, I have a deployed SAS job runs in flow which always fails during the first run and after we re -run manually it will get succeeded. The issue is due to sql server stored procedure which we call in it in the SAS job. So we thought of adding exception handling in the schedule manager for that job. We have defined that 'if the job fails with exit code greater than zero, we asked it to re-run automatically', But its not working. Is there any other way to remove the manual process of re run ? Thanks
... View more