mirror of
https://github.com/sasjs/core.git
synced 2026-01-10 10:50:04 +00:00
Merge pull request #81 from sasjs/issue80
fix: removing nonprintables from cards data. Closes #80
This commit is contained in:
9
all.sas
9
all.sas
@@ -3474,7 +3474,12 @@ data datalines_2;
|
|||||||
*/
|
*/
|
||||||
else if upcase(format)=:'$HEX' then
|
else if upcase(format)=:'$HEX' then
|
||||||
dataline=cats('put(trim(',name,'),',format,')');
|
dataline=cats('put(trim(',name,'),',format,')');
|
||||||
else dataline=name;
|
/**
|
||||||
|
* There is no easy way to store line breaks in a cards file.
|
||||||
|
* To discuss this, use: https://github.com/sasjs/core/issues/80
|
||||||
|
* Removing all nonprintables with kw (keep writeable)
|
||||||
|
*/
|
||||||
|
else dataline=cats('compress(',name,', ,"kw")');
|
||||||
run;
|
run;
|
||||||
|
|
||||||
proc sql noprint;
|
proc sql noprint;
|
||||||
@@ -3551,7 +3556,7 @@ data _null_;
|
|||||||
put 'run;';
|
put 'run;';
|
||||||
end;
|
end;
|
||||||
else do;
|
else do;
|
||||||
put "infile cards dsd delimiter=',';";
|
put "infile cards dsd;";
|
||||||
put "input ";
|
put "input ";
|
||||||
%do i = 1 %to &nvars.;
|
%do i = 1 %to &nvars.;
|
||||||
%if(%length(&&input_stmt_&i..)) %then
|
%if(%length(&&input_stmt_&i..)) %then
|
||||||
|
|||||||
@@ -161,7 +161,12 @@ data datalines_2;
|
|||||||
*/
|
*/
|
||||||
else if upcase(format)=:'$HEX' then
|
else if upcase(format)=:'$HEX' then
|
||||||
dataline=cats('put(trim(',name,'),',format,')');
|
dataline=cats('put(trim(',name,'),',format,')');
|
||||||
else dataline=name;
|
/**
|
||||||
|
* There is no easy way to store line breaks in a cards file.
|
||||||
|
* To discuss this, use: https://github.com/sasjs/core/issues/80
|
||||||
|
* Removing all nonprintables with kw (keep writeable)
|
||||||
|
*/
|
||||||
|
else dataline=cats('compress(',name,', ,"kw")');
|
||||||
run;
|
run;
|
||||||
|
|
||||||
proc sql noprint;
|
proc sql noprint;
|
||||||
@@ -238,7 +243,7 @@ data _null_;
|
|||||||
put 'run;';
|
put 'run;';
|
||||||
end;
|
end;
|
||||||
else do;
|
else do;
|
||||||
put "infile cards dsd delimiter=',';";
|
put "infile cards dsd;";
|
||||||
put "input ";
|
put "input ";
|
||||||
%do i = 1 %to &nvars.;
|
%do i = 1 %to &nvars.;
|
||||||
%if(%length(&&input_stmt_&i..)) %then
|
%if(%length(&&input_stmt_&i..)) %then
|
||||||
|
|||||||
Reference in New Issue
Block a user