Natural/Adabas Call api's

Hello,

Where can I find a list (with explanations & examples) of these api’s?

Ex: call ‘cmroll’

Thanks,
Hezi

Hi Hezi,

‘cmroll’ as you mention is an internal function that is not documented.

For official supported Natural API’s you can look in Natural library SYSEXT. There they are also documented.

Just in case CMROLL was the main objective of your post:

Here is a program which uses the employees demo file

DEFINE DATA LOCAL
1 MYVIEW VIEW OF EMPLOYEES
2 NAME
1 #DELAY (I2) INIT <1>
END-DEFINE
*
READ MYVIEW IN LOGICAL SEQUENCE BY NAME
AT BREAK OF NAME /1/
WRITE 3/10 'UP TO THE LETTER: ’ NAME (AL=1)
SET CONTROL ‘N’
NEWPAGE
END-BREAK
END-READ
END

If you run this, the letters will flash by too fast to read. HOWEVER, if you add the statement CALL ‘CMROLL’ #DELAY after the AT BREAK, there will be a one second delay effected. This will allow you to see all the letters.

On the mainframe & PC, #DELAY, the argument for CMROLL, can be I2 or I4 (I believe the documentation says only I2, I will check on this). Do NOT use I1; it goes off into never never land if you do.

steve

Hi,

I know cmroll, my question was :
what are all the api’s that are not documented (like cmroll)?

Hezi

Exactly; if you got a call ‘xyz’ you would like to use, go to SYSEXT and see if there is an equivalent.

The feature of ‘cmroll’ is supported by SYSEXT / USR2027N.

SYSEXT also gives you a list of supported APIs.

Hi Hezi;

If at all possible, stay away from unsupported and/or undocumented “stuff”. It is an invitation to trouble (in all languages/systems).

Years ago (V2.2?) I was having a beer at a conference with some of the developers. I learned about an undocumented feature.

COMPRESS #A #B #C if #B were blank, would have only one delimiter between #A and #C, but COMPRESS FULL #A #B #C would have two delimiters. I told a number of people, who told other people, etc.

When version 3 came out, there was a documented option, COMPRESS FULL, which really is not a compress, but a concatenate. The functionality of the extra delimiter was documented as COMPRESS … WITH ALL DELIMITERS.

After apologizing to everyone I knew who used the undocumented FULL and suffered when the “real” FULL was added to the language; I vowed to avoid such ventures into the undocumented and unsupported.

steve

Yeah even I want a list with explanations and examples of APIs available. Can someone help?

Calls to the Natural nucleus (CALL ‘CMxxx’) were intended only for internal use and remain undocumented. They are not to be considered components of the Application Programming Interface.

Over time some entry points were ‘leaked’ to the user community, so to stem the tide, Software AG introduced an official API, the SYSEXT library. There you will find scores of user exits (subprograms named USR####N), documented and searchable. You should expect to find a counterpart to each CM routine.

There are Natural administrators who consider some user exits to be dangerous enough to bar access to SYSEXT. (For example you can terminate any CICS user session.) If you can’t convince your Admin to allow access, you can still learn about the exits and test them by installing Natural for Windows Community Edition. Many routines are common to both mainframe and Windows.

Use of the CM routines in your applications should be discontinued.