OS Version

Tags:
Application development
AS/400
CLP
DataCenter
How can I determine what OS Version is installed on my system from a program? The OS version is not in the system values, RTVJOBA, or RTVNETA.

Answer Wiki

Thanks. We'll let you know when a new response is added.

Retrieve data area QSS1MRI out of library QUSRSYS. The first 6 characters contain the full version-release-modification code. You can do this is an RPG or CL program.

Discuss This Question: 5  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • astradyne
    You can pick it up using the QSZRTVPR system API either by calling directly or using within a sub-procedure. I use the following sub procedure: Prototype: *----------------------------------------------------- * Common API Error Structure *----------------------------------------------------- D/IF NOT DEFINED(API_ERROR) D/DEFINE API_ERROR D ApiError DS D ApiBytes 10I 0 Inz(%Size(ApiError)) D ApiBytesOut 10I 0 D ApiErrID 7A D ApiReserved 1A D ApiErInDta 256A D/ENDIF *----------------------------------------------------- * Retrieve OS/400 Version *----------------------------------------------------- D RtvOS400Ver pr 6a D QszRtvPR pr ExtPgm('QSZRTVPR') D verRcvVar Like(Prdr0100) D verRcvLen 10i 0 Const D verFormat 8a Const D verPrdInf 27a Const D verError Like(ApiError) D Prdr0100 ds D PrdBytReturn 10i 0 D PrdBytAvail 10i 0 D PrdReserve_1 10i 0 D PrdID 7a D PrdVersion 6a D PrdOption 4a D PrdLoadID 4a D PrdLoadType 10a D PrdSymbState 10a D PrdLoadErr 10a D PrdLoadState 2a D PrdSupported 1a D PrdRegType 2a D PrdRegValue 14a D PrdReserved_2 2a D PrdOffAddInf 10i 0 D PrdPrimLang 4a D PrdMinTgtRls 6a D PrdMinBaseVRM 6a D PrdReqMet 1a D PrdLevel 3a D OS400Rls c Const('*OPSYS *CUR 0000*CODE ') (spacing on the OS400Rls constant is 1, 2, 5) Procedure: P RtvOS400Ver b Export * Procedure interface D RtvOS400Ver pi 6a * Procedure calculation specifications * Call the API... C Reset ApiError C CallP QszRtvPr(PrdR0100 : %len(PrdR0100) : C 'PRDR0100' : OS400Rls : ApiError) C If ApiBytesOut 0 C Return '*ERROR' C Else C Return PrdVersion C EndIf P RtvOS400Ver e Hope it helps Jonathan
    370 pointsBadges:
    report
  • Senator46058
    An easy way is to check a compile listing. The release (V5R2) is located on the listing. Have a great day.
    0 pointsBadges:
    report
  • Jadima
    The easiest way to retrieve the OS level is like this : DCL VAR(&SYSLVL) TYPE(*CHAR) LEN(9) RTVOBJD OBJ(QSYS) OBJTYPE(*LIB) SYSLVL(&SYSLVL) in &syslvl you have the os level in format 'V05R04M00' Good luck
    0 pointsBadges:
    report
  • DaddyCOZ
    I think the easiest and best way is to use this system API; it is easy to call and to use. * D CEEGPID PR D version 10I 0 D platform 10I 0 D ver s 10I 0 D plat s 10I 0 D* c callp ceegpid(ver:plat) c if ver >= 520
    0 pointsBadges:
    report
  • Fpalinkas
    If it is for a program try command WRKPGM and take option 5
    0 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following