DATA Step, Macro, Functions and more

Format not found for batch-processing (while OK for EGuide)

Reply
Occasional Contributor
Posts: 6

Format not found for batch-processing (while OK for EGuide)

Hi,

 

One of my SAS-users receives following error when executing her sas-code via command line (batch mode): ./sas + sas-file

ERROR: The informat Z was not found or could not be loaded

 

The format "Zw" is a standard format (no informat as error indicates)

When executing her sas-code via EGuide then no ERROR received while error when via batch-mode.

 

I've checked the OPTION FMTSEARCH for EGuide (working fine) and batch mode (not OK) :

Via EGuide : FMTSEARCH=( APFMTLIB WORK LIBRARY )

with APFMTLIB = SASEnvironment/SASFormats -> no files in this folder
Via batch mode :  FMTSEARCH=(WORK LIBRARY)

 

What can be cause of this issue?

Thanks.

 

FYI. snippet producing error :

 proc Sql;

                create table &lib_tmp..&dataset_vat._entr as

                    select distinct t1.*,

                        t2.C_CODEENTRPSTATU_CODE,

                        t2.D_I_INSCR_KBO as BeginDatumONKBO,

                        t2.D_I_KBO_CLOT as EindDatumONKBO,

                        t2.D_I_DEBUT as OprichtingsDatum,

                        t2.D_I_CESS as BeeindigingsDatum

                    from &lib_output..&dataset_vat.(where=(substr(put(C_I_ENTRP_NUM,z10.),1,1)^="2")) as t1

                        left join &SITRAN..ENTREPRISE_ETABLISSEMENT as t2 on (t1.C_PERS_IDF=t2.C_PERS_IDF);

            quit;

PROC Star
Posts: 263

Re: Format not found for batch-processing (while OK for EGuide)

Sounds like the format library APFMTLIB contains an informat named Z, which is assigned to one or more variables on the input table. Zw. may be a standard format, but that does not stop you from creating an informat with the same name. 

SAS Employee
Posts: 199

Re: Format not found for batch-processing (while OK for EGuide)

Hi @jurlis

 

I think the difference in behaviour is due to the FMTERR System Option.

With SAS Enterprise Guide (EG), the option is set to NOFMTERR while in batch you may have FMTERR.

You can compare the two values by running:

proc options option=fmterr;
run;

I'm guessing that with EG, if you change the value to FMTERR you'll have the same result as you have in batch.

So if you set NOFMTERR in batch, you should not have the error and the result should be the same as the one you have with EG.

 

Hope that helps.


Cheers,
Damo

 

Ask a Question
Discussion stats
  • 2 replies
  • 131 views
  • 0 likes
  • 3 in conversation