mirror of
https://github.com/sasjs/core.git
synced 2025-12-21 02:01:20 +00:00
fix: avoid sending BOM marker to SASjs API
This commit is contained in:
12
all.sas
12
all.sas
@@ -8239,7 +8239,8 @@ options
|
|||||||
%end;
|
%end;
|
||||||
;
|
;
|
||||||
|
|
||||||
%mend mp_init;/**
|
%mend mp_init;
|
||||||
|
/**
|
||||||
@file mp_jsonout.sas
|
@file mp_jsonout.sas
|
||||||
@brief Writes JSON in SASjs format to a fileref
|
@brief Writes JSON in SASjs format to a fileref
|
||||||
@details PROC JSON is faster but will produce errs like the ones below if
|
@details PROC JSON is faster but will produce errs like the ones below if
|
||||||
@@ -18937,12 +18938,16 @@ run;
|
|||||||
,mdebug=0
|
,mdebug=0
|
||||||
);
|
);
|
||||||
|
|
||||||
%local fname0 fname1 fname2 boundary fname statcd msg;
|
%local fname0 fname1 fname2 boundary fname statcd msg optval;
|
||||||
%let fname0=%mf_getuniquefileref();
|
%let fname0=%mf_getuniquefileref();
|
||||||
%let fname1=%mf_getuniquefileref();
|
%let fname1=%mf_getuniquefileref();
|
||||||
%let fname2=%mf_getuniquefileref();
|
%let fname2=%mf_getuniquefileref();
|
||||||
%let boundary=%mf_getuniquename();
|
%let boundary=%mf_getuniquename();
|
||||||
|
|
||||||
|
/* avoid sending bom marker to API */
|
||||||
|
%let optval=%sysfunc(getoption(bomfile));
|
||||||
|
options nobomfile;
|
||||||
|
|
||||||
data _null_;
|
data _null_;
|
||||||
file &fname0 termstr=crlf;
|
file &fname0 termstr=crlf;
|
||||||
infile &inref end=eof;
|
infile &inref end=eof;
|
||||||
@@ -19003,6 +19008,9 @@ run;
|
|||||||
,msg=%superq(msg)
|
,msg=%superq(msg)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
/* reset options */
|
||||||
|
options &optval;
|
||||||
|
|
||||||
%mend ms_createfile;
|
%mend ms_createfile;
|
||||||
/**
|
/**
|
||||||
@file
|
@file
|
||||||
|
|||||||
@@ -29,12 +29,16 @@
|
|||||||
,mdebug=0
|
,mdebug=0
|
||||||
);
|
);
|
||||||
|
|
||||||
%local fname0 fname1 fname2 boundary fname statcd msg;
|
%local fname0 fname1 fname2 boundary fname statcd msg optval;
|
||||||
%let fname0=%mf_getuniquefileref();
|
%let fname0=%mf_getuniquefileref();
|
||||||
%let fname1=%mf_getuniquefileref();
|
%let fname1=%mf_getuniquefileref();
|
||||||
%let fname2=%mf_getuniquefileref();
|
%let fname2=%mf_getuniquefileref();
|
||||||
%let boundary=%mf_getuniquename();
|
%let boundary=%mf_getuniquename();
|
||||||
|
|
||||||
|
/* avoid sending bom marker to API */
|
||||||
|
%let optval=%sysfunc(getoption(bomfile));
|
||||||
|
options nobomfile;
|
||||||
|
|
||||||
data _null_;
|
data _null_;
|
||||||
file &fname0 termstr=crlf;
|
file &fname0 termstr=crlf;
|
||||||
infile &inref end=eof;
|
infile &inref end=eof;
|
||||||
@@ -95,4 +99,7 @@ run;
|
|||||||
,msg=%superq(msg)
|
,msg=%superq(msg)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
/* reset options */
|
||||||
|
options &optval;
|
||||||
|
|
||||||
%mend ms_createfile;
|
%mend ms_createfile;
|
||||||
|
|||||||
Reference in New Issue
Block a user