Return value on AS400

Posted on 2006-03-22
Last Modified: 2011-10-03

Can anybody tell me the limit of error value returned on AS/400 system.
For MVS the limit is 0 - 4096.


Question by:dhumal
    LVL 26

    Accepted Solution


    Error value returned for what? errno? SQL error values returned? Error values returned from an application program?

    errno on V5R1 generally ranges 3001-3536, but those are the basic values #defined in errno.h. In V5R3, the range is 3001-3546.

    Of course, the #defined values don't limit it. If the #defined range goes 3546, I would expect at least values to 4095.


    LVL 9

    Expert Comment

    You need to know the application, eg. SQL, RPG, CPF etc.

    In general error messages are in the format

    where AAA is actualy 1 alpha and two alphanumerics and identifies the application, and sometimes a clue to the message file containing the message
    and 9999 is a four digit number...  in hex: digits 0-9 and characters A-F

    I would have said the limit is 0000-FFFF,  although generally 0001-9999    (although not all numbers are used)

    Error messages are stored in MESSAGE FILES  (*MSGF).

    You can create your own message file(s), and create your own message id's but the message id has to follow the above convention.

    examples of IBM supplied message files (assuming you have the applications loaded) are
    the list goes on and on and on......

    try the command WRKMSGF   *LIBL/*ALL  
    and choos option 12 to view messages....
    eg. QSQLMSG has the following messages  
    QMR0A1A - QMR2204
    QMX0001 - QMX0191
    SQL0004 - SQL9108
    SQT0100 - SQT6842
    SQ20054 - SQ20268
    SQ30000 - SQ30107

    NOTE that not all numbers in a range are used !! eg. QSQLMSG has the following extract
    Message ID  Severity  Message Text                              
     QMR0A1A       10       Field value must be in the range 1 to 255.
     QMR0A1B       10       Field value must be in the range 22 to 378.
     QMR0A10       10       Field value must be in the range 1 to 4.  
     QMR0A11       10       Field value must be in the range 0 to 99.  
     QMR0A12       10       Field value must be in the range 0 to 999.
     QMR0A15       10       Field value must be in the range 0 to 15.  

    notice messages QMR0A13 or QMR0A14 don't exist.


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    These days socially coordinated efforts have turned into a critical requirement for enterprises.
    For Sennheiser, comfort, quality and security are high priority areas. This paper addresses the security of Bluetooth technology and the supplementary security that Sennheiser’s Contact Center and Office (CC&O) headsets provide.  
    To add imagery to an HTML email signature, you have two options available to you. You can either add a logo/image by embedding it directly into the signature or hosting it externally and linking to it. The vast majority of email clients display l…
    This video discusses moving either the default database or any database to a new volume.

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now