I'm attempting to reorganize some code and start utilizing GitLab for my organization. My plan is to commit our code base with following structure directory/[Main] etl.egp build.egp validation.egp parameters.sas [build-programs] [build-inputs] [etl-programs] [validation-programs] within build.egp I run parameters.sas with an %include statement: data _null_;
name = dequote(&_clientprojectpath);
cutofflen = length(&_ClientProjectNAME)+3;
namelen = length(name);
path = cats('\\company.com\Shares\Projects',substr(name,3,namelen-cutofflen)); *starts string after X: with sas filepath type and drops project name;
path2 = substr(path,1,length(path)-5); *drops \Main path;
param_CodeRef = cat(trim(path),"\parameters-0622.sas");
call symput('param_code', param_CodeRef);
call symput('egp_location',path);
call symput('base_directory',path2);
run;
%include "¶m_code."; *snippet of related code from parameters.sas file
%let dir_build = &base_directory.\Production\&yyyy.\&mm.\Build;
%let dir_prep = &dir_build.\Source; The problem is that the variable has a line split (enter key) causing the %let statement to create multiple records in macro variable value viewer, neither of them usable. e.g. %put &dir_prep.; output; "&base_directory. [actual directory does output] \Production\2022\06\Build" I think my near term problem is solved if I can create %let statements with &base_directory. and no enter keys. possible causes of problem: Line insert in macro variable declared in _null_ data step relative file references under project properties, (speculation that it's truncating path relative to file location). file paths are pretty long (directory =127 char)
... View more