Desktop productivity for business analysts and programmers

ERROR: The format CHAR was not found or could not be loaded

Accepted Solution Solved
Reply
Contributor
Posts: 28
Accepted Solution

ERROR: The format CHAR was not found or could not be loaded

Hello,

 

I've made a project with a text prompt, where the users enter a cardnumber of 16 digits, the library I used seems doesn't have format catalog, so when I try to create the stored process I get the error related to the prompt:

 

ERROR: The format CHAR was not found or could not be loaded.

 

I've try to create user-defined format and load format from another library but it hasn't work.

I noticed in the log that the library don't use the sas engine:

 

NOTE: Libref MONFRA was successfully assigned as follows:
Engine: SQLSVR.

 

What can I do?


Accepted Solutions
Solution
‎02-05-2018 01:37 PM
Super User
Posts: 23,963

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to rodrichiez
(INPUT (PUT(t1.C07507, 8.),yymmdd8.)) FORMAT=ddmmyys10. AS FECHA_TRX,

Yeah that doesn't work, you're converting a numeric to character so you need a numeric format. 

Try 8. instead of CHAR8

 

 

View solution in original post


All Replies
Super User
Posts: 6,918

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to rodrichiez

SAS contains a set of related formats such as $char2., $char3., etc.  They would be used to print character variables, preserving leading blanks.

 

You would receive this sort of error if you attempted to apply one of these formats to a numeric variable.  That's the first thing to check.

Contributor
Posts: 28

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to Astounding
The column is alphanumeric and I pass a text value through the prompt.
Super User
Posts: 23,963

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to rodrichiez

Can you show the section of code that generates that error then?

Contributor
Posts: 28

Re: ERROR: The format CHAR was not found or could not be loaded

Hi @Reeza

 

Here is the section of code, the error refer to the 291 line:

 

248 +
249 +PROC SQL;
250 + CREATE TABLE WORK.QUERY_FOR_EVENTOS750 AS
251 + SELECT t1.C07500,
252 + t1.C07503,
253 + t1.C07504,
254 + t1.C07553,
255 + t1.C07560,
256 + /* FECHA_TRX */
257 + (INPUT (PUT(t1.C07507, char8.),yymmdd8.)) FORMAT=ddmmyys10. AS FECHA_TRX,
258 + t1.HORA,
259 + t1.C07508 FORMAT=BEST12.,
260 + t1.C07510 FORMAT=BEST12.,
261 + t1.C07543 FORMAT=BEST12.,
262 + t1.C07511,
263 + t1.C07513 FORMAT=BEST12.,
The SAS System

264 + t1.C07514,
265 + t1.C07515,
266 + t1.C07516,
267 + t1.C07517,
268 + t1.C07518,
269 + t1.C07528,
270 + t1.C07519,
271 + t1.C07568,
272 + t1.C07569,
273 + t1.C07535,
274 + t1.C07521,
275 + t1.C07522,
276 + t1.C07524,
277 + t1.C07525,
278 + t1.C07577,
279 + t1.C07584,
280 + t1.C07585 FORMAT=BEST12.,
281 + t1.C07589 FORMAT=BEST12.,
282 + t1.C07590 FORMAT=BEST12.,
283 + t1.C07592,
284 + t1.C07803,
285 + t1.C07530,
286 + t1.C07807 FORMAT=BEST12.,
287 + t1.FRAUDE
288 + FROM MONFRA.EVENTOS750 t1
289 + WHERE %_eg_WhereParam( (CALCULATED FECHA_TRX), FECHA_CONSULTA_min, GE, TYPE=D, IS_EXPLICIT=0 ) AND
290 + %_eg_WhereParam( (CALCULATED FECHA_TRX), FECHA_CONSULTA_max, LT, TYPE=D, IS_EXPLICIT=0 ) AND t1.C07500 =
291 + "&NRO_TARJETA";
ERROR: The format CHAR was not found or could not be loaded.

Super User
Posts: 23,963

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to rodrichiez

And the rest of the log....

Contributor
Posts: 28

Re: ERROR: The format CHAR was not found or could not be loaded

@Reeza

 

Find attached the log.

 

Regards.

Solution
‎02-05-2018 01:37 PM
Super User
Posts: 23,963

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to rodrichiez
(INPUT (PUT(t1.C07507, 8.),yymmdd8.)) FORMAT=ddmmyys10. AS FECHA_TRX,

Yeah that doesn't work, you're converting a numeric to character so you need a numeric format. 

Try 8. instead of CHAR8

 

 

Contributor
Posts: 28

Re: ERROR: The format CHAR was not found or could not be loaded

@Reeza

But the error is in line 291:

t1.C07500 = "&NRO_TARJETA";

Super User
Posts: 23,963

Re: ERROR: The format CHAR was not found or could not be loaded

Posted in reply to rodrichiez

rodrichiez wrote:

@Reeza

But the error is in line 291:

t1.C07500 = "&NRO_TARJETA";


Did you try making the change? Was the error still there?

Contributor
Posts: 28

Re: ERROR: The format CHAR was not found or could not be loaded

You're right @Reeza. This is the solution.

 

Thank you very much! Smiley Very Happy

☑ This topic is solved.

Need further help from the community? Please ask a new question.

Discussion stats
  • 10 replies
  • 398 views
  • 2 likes
  • 3 in conversation