[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x

IBM System i

IBM i, formerly known as AS/400, is a proprietary, midrange, object-based operating and application system. It includes a relational database, a menu-driven interface, support for multiple users, block-oriented terminal support and printers, and supports security, communications, and web-based application servers including Websphere, Apache and Tomcat.

Share tech news, updates, or what's on your mind.

Sign up to Post

Hi experts,

I have some pointer questions for some time, but now I finally want to know. :-)

Why Can't I use :
    callp MyProgram(%addr(Var1:%addr(Var2))
This give a compile error.

Why Can't I use a pointer in my pi parameter directly?
a Data-structure based on a incoming parameter pointer will show only '*****' values.
(now I have to base it an an other pointer, and fill that one with the parameter value).

I did read the Scott version of "messing around with pointers", but I cant find the answer there :-)
0
CompTIA Cloud+
LVL 12
CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

Is it possible to retrieve a listing from audit journals  on the IBM i, of all user's that answer a 'spool' file message?
0
I was sending XML in SOAP envelope to a web consuming server here at Lone Star. The Web consuming service has now switched from XML to JSON. Does the SOAP envelope change? If so in what way? I'm attaching the actual output to the Web Service. Using Krengeltech's RPG-XML to generate the XML data formatted and wrapping it in the SOAP envelope. Krengeltech also has a JSON api to perform the data mapping in JSON instead of XML. I need help creating the 'wrapped' soap statements
0
On IBM i, Is there any way to find the name of an IBM i object from a pointer (ex...80000000000000000000040190010000)?
0
I could use some help with my script. I put *** where I need help making a code that would auto enter the most recent sundays date. Could you help?

[PCOMM SCRIPT HEADER]
LANGUAGE=VBSCRIPT
DESCRIPTION=
[PCOMM SCRIPT SOURCE]
OPTION EXPLICIT
autECLSession.SetConnectionByName(ThisSessionName)

REM This line calls the macro subroutine
subSub1_

sub subSub1_()
   autECLSession.autECLOIA.WaitForAppAvailable
   
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "[tab]"
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "158"
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "[field+]"
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "5"
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "[enter]"
   
   autECLSession.autECLPS.WaitForAttrib 10,56,"00","3c",3,10000

   autECLSession.autECLPS.WaitForCursor 10,57,10000

   autECLSession.autECLOIA.WaitForAppAvailable
   
   autECLSession.autECLOIA.WaitForInputReady
   ***Input the most recent sunday's date.
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "[field+]"
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "[field+]"
   autECLSession.autECLOIA.WaitForInputReady
   autECLSession.autECLPS.SendKeys "580171"
end sub
1
Hi Experts,

I have some SQLRPGLE problems with reading a tabel (with null capable fields)
The program reads a record in a DS , change 2 fields and write it to a remote (identical) table.

But I have to add a null "check field" per field
exec sql fetch next from cIMPH INTO
 :DS_REFERENCE       :ISNUL1,          
 :DS_CONTEXT         :ISNUL2,          
 :DS_OBJECT_TYPE     :ISNUL3;

In this example it's not a problem, but I need to do this for a file with round 100 fields.
So I prefer to use the SQL

exec sql fetch next from cIMPH INTO :DS;

On top of that, if I use the null-check field, the original field contains a space or a zero.
the remote table expect null values.

How can I solve this?
0
I need to get guidance on proper storage of an as400. I believe it is running system 38 (or 36).

Regards, George
0
Hi Experts,

On a Website I found a link to create webservices with a standard tool that is available on the IBMi "/QIBM/ProdData/OS/WebServices/V1/client/bin/wsdl2rpg.sh"
The result is a Service program that contains all required info to call the webservice.

I'm able to fill the WS variables, but I can't find where and how I can add header elements like :
<httpHeader>                          
     <header name="Accept-Encoding" value="gzip,deflate"/>               
     <header name="Api-Key" value="123456"/>   
     <header name="Host" value="api.web123.com "/>        
     <header name="Connection" value="Keep-Alive"/>                 
</httpHeader>   

Open in new window

(of course, the value data is variable)
How can I add these to the WS-header  

Thanks
0
Dears,

I have a Qlogic issue in IBM BladeCenter, Blade HS22 and LS42.

as attached picture no  device present in Fiber Channel Device.


Regards,
Saeed
Blade5.jpg
0
Hi All

Greetings!!!

Hope you are well.

I need to copy a Schema from one machine to other machine,

Both machines have Db2 instance of same version (10.5)

But Schema is having data of LOB data type.

Which method is simple to copy the entire schema with structure and data.

I know ADMIN_COPY_Schema only supports on same machine and under same instance .

But db2move utility does not support LOB data type (I think).

Any inputs on this Please.

Thanks in Advance!!!!
0
Amazon Web Services
LVL 12
Amazon Web Services

Are you thinking about creating an Amazon Web Services account for your business? Not sure where to start? In this course you’ll get an overview of the history of AWS and take a tour of their user interface.

Hi, we have two tapes to be used for daily backup. and we have scheduled jobs to run the daily backups at night. previously, we only need 1 tape but now, it asks for 2nd tape. we have a program to initialize single tape, but not for 2 tapes. can anyone helps on how to intialize more than 1 tape  for daily backup   (1 week rotation basis). 2 tape cartridges per day, 14 tapes/week. os version: v6r1. thanks.
      PGM                                                                
      DCL VAR(&DAY) TYPE(*CHAR) LEN(4)                                  
      DCL VAR(&DLYVOL) TYPE(*CHAR) LEN(6)                                
      RTVSYSVAL SYSVAL(QDAYOFWEEK) RTNVAR(&DAY)                          
      CHGVAR VAR(&DLYVOL) VALUE('DLY' *CAT %SST(&DAY 2 3))              
      INZTAP DEV(tapxx) NEWVOL(&DLYVOL) NEWOWNID(xxxx) CHECK(*NO) -
 ENDOPT(*REWIND)                                                        
      ENDPGM
0
Hi experts,

I recently discovered the "SYSTOOLS.HTTPPOSTCLOB" to consume webservices
As long as I give the right input to the WS, it works fine, but I can't figureout how to catch errors.

e.g. I send a wrong ZipCode a Zipcode-service to get an address.
If I do that in SoapUI I get the information:
{"errors": [{
   "status": "400",
   "title": "Bad Request",
   "detail": "postalcode has the wrong format. It should be: 9999XX"
}]}

Open in new window

If i do the same request with SYSTOOLS.HTTPPOSTCLOB, the response is empty (I assume null),
result : GDATA_DATA          CHAR(8000000)        NOT ADDRESSABLE

SQLCODE = -4302
SQLSTATE = '38000'

SQL Diagnostics data:
        ....5...10...15...20...25...30...35...40...45...50...55...60 
   1   'COMMAND_FUNCTION=VALUES INTO;COMMAND_FUNCTION_CODE=-66;DB2_N'
  61   'UMBER_CONNECTIONS=+1;DB2_SQL_ATTR_CONCURRENCY=R;DB2_SQL_ATTR'
 121   '_CURSOR_CAPABILITY=R;DB2_SQL_ATTR_CURSOR_HOLD=N;DB2_SQL_ATTR'
 181   '_CURSOR_ROWSET=N;DB2_SQL_ATTR_CURSOR_SCROLLABLE=N;DB2_SQL_AT'
 241   'TR_CURSOR_SENSITIVITY=S;DB2_SQL_ATTR_CURSOR_TYPE=F;MORE=N;NU'
 301   'MBER=+1;CLASS_ORIGIN=ISO 9075;CONDITION_NUMBER=+1;DB2_MESSAG'
 361   'E_ID=SQL4302;DB2_MESSAGE_ID1=CPF503E;DB2_MODULE_DETECTING_ER'
 421   'ROR=QSQVALUE;DB2_ORDINAL_TOKEN_1=SYSTOOLS.HTTPPOSTCLOB;DB2_O'
 481   'RDINAL_TOKEN_2=HTTPP00013;DB2_ORDINAL_TOKEN_3=java.net.Malfo'
 541   'rmedURLException:no protocol:                               '
 601   '                                  

Open in new window

0
Hi Experts,

We are getting the error message CPF5033 during READ operation in batch program and error message says the below.
"I/O error CPF5033 was detected in file B1PBILH (C G D F)."

When I check the log it says
" Select or omit error on field B1PBILH_1.BTCAR member B1PBILH.  
 Select/omit error on member B1PBILH.                            "

"I/O error CPF5033 was detected in file B1PBILH.                          
Function check. RNX1299 unmonitored by BLR573R1A at statement 0000048100,
  instruction X'0000'.                                                    "

I have checked the record lock and object lock on the file. No locks exist.
I have checked the data for the particular record where to check the junk value. No junk value exist.
And we are getting this error randomly for different records.

Program flow:
Cl program does the OVRDBF and then opnqry on the file and we read the same file in RPGLE with out key.
and we are getting CPF5033 error while performing the read operation on the file.

Please help me to fix the issue. I have attached the screen shot for your reference.


Thanks in advance.

Regards,
Sri
0
While do save/restore operation on *LINK in AS400,I am getting error  "File system error occurred. error number 3474
0
hi.  I am trying to configure mail on the iSeries or AS400.   My only ISP I have access to is verizon.  They have no SMTP servers you can use.  How can I configure the system to send out mail?  I am have other questions concerning this, but can't seem to find one if you have no access to an smtp server.
0
I had this question after viewing Display file Overlay problem.

I have the same problem but with window formats, three of them. Each is in its own program and display file. When program A is called from the menu, it displays its window leaving the original menu screen intact. From activity performed on that window, another program is called, program B, which also displays a window but now, everything behind it is black. This behavior continues for the next program which also displays a window and a black background eliminating everything  previously displayed up to this point.

I have a dummy format in each program with the ASSUME keyword and the one character field at 1,2 and even added the KEEP keyword but it made no difference.

I have not set row and column positions but have selected the default positioning option expecting the OS to position each screen to avoid any issues but obviously, this isn't happening.

Any suggestions?
Mike.
0
We have an issue right now where when our cust service team runs a credit card they at times receive a handshake error. We run a IBM i AS/400 that connects to a backend called Curbstone. Here is a break down of how this works Here is what is supposed to happen.

When credit cards are run curbstone opens a connection to paymenttech.
At this point the IBM I sends along “cipher suite, decryption keys” this information is accepted by paymenttech and the transaction continues.

Here is what is happening now.
Curbstone opens a connection to paymenttech.  At this point the IBM I sends along “cipher suite, decryption keys” this information is now rejected by paymenttech the transaction fails and the handshake error pops up. I have run a trccnn on the IBM i and in wireshark. Both curbstone and paymenttech don't see any issues on their end. I did call paymenttech today and a transaction that I saw on the IBM i didn't get to them resulting in the handshake error. I don't think its an issue with our network because it isn't a constant issue. I thought perhaps there was some job running at the time of the handshake error but that doesn't seem to be an issue. This issue ramps up at between 4pm and 6pm on Fridays. Why? I can't seem to find a reason.
TLS_FAILED_HANDSHAKE.pcap
0
Hi,
Does anyone know of a technique of locking an IBM i spool file so it cannot be deleted while a process is running?

Thank you,
0
How to do manual IPL from HMC on AS400 server . Am not having physical access to server. All remote access to the partition.
What settings should i change?
0
OWASP Proactive Controls
LVL 12
OWASP Proactive Controls

Learn the most important control and control categories that every architect and developer should include in their projects.

i just need to pass an array to rpg from java but its not running error free.
here is my code

import com.ibm.as400.access.*;
import java.beans.PropertyVetoException;
import java.io.IOException;

public class CallingArrayPgm {
    public static void main(String[] args) throws PropertyVetoException{
      try{
                  
            AS400 sys=new AS400("192.168.111.211", "THARINDU", "GAYAN@123");            
            
                  int[] accounts = new int[5];
             
             AS400Array accountsarray = new AS400Array();
               
               
            ProgramParameter[] parmList1 = new ProgramParameter[1];
                ProgramParameter[] parmList2 = new ProgramParameter[1];
               
                parmList2[0] = new ProgramParameter(accountsarray.toBytes(accounts),5);  
               
             ProgramCall pgm = new ProgramCall(sys,"/QSYS.LIB/THALIB.LIB/ARRAYTEST.PGM",parmList2);
             
                 if (pgm.run()!=true) {
                System.out.println("executed");
            }else{
                   
                    AS400Text text = new AS400Text(30);
                     sys.disconnectService(AS400.COMMAND);
                   
            }
               
                AS400Message[] messageList = pgm.getMessageList();
                System.out.println(messageList.length + "TEst ok");
        
              sys.disconnectService(AS400.COMMAND);
              
            }catch(AS400SecurityException | ErrorCompletingRequestException | ObjectDoesNotExistException | IOException | InterruptedException e) {
                  System.out.println(e.toString());
      …
0
Hi am trying to add objects in my endevour am geting the above error
0
Greetings AS/400 Gurus...

I'm attempting to tackle the upgrade from V7R1 to V7R2...
I've downloaded and loaded my keys on WRKLIC...
I've downloaded the zipped files for my Entitled Software for the V7R2 update.
I used Dowload Director and I have all of the files on my PC...
They are all still zipped...

I need to know what to do next...
I want to use Image Catalogs to perform the install of the update to V7R2...
It's been so long since I've done this, I am struggling to remember the process of moving the objects into the image catalogs on the iSeries disk... I seem to recall that I need to get the stuff from my PC onto the IFS... I'm just not sure of the process...

Do I need to unzip the files...?
Do I need to put them in a specific place on the IFS...?

I have this link:
https://www.ibm.com/support/knowledgecenter/ssw_ibm_i_71/rzahc/scenarioprepareimagecatalog.htm
But I need to move the files to the IFS before I get to this step...

Any input will be appreciated...
0
I have a call program...example: CALL PGM (DELTE/RECV)...that I want to run in two different environments...Production (PROD2) and Test (TEST2).  My question is...how can I specifically run the program separately in both environments.  In other words, I want to run it in test, then run it in production.  Thank you in advance for your assistance!
0
I want to create user who is going to see all the user profile and group profiles but should not having access to changes or delete any thing on AS400 machine.

To achieve this i have created User having following permissions-

User class           - *USER
Special authority - *ALLOBJ
 
With this user, we can read all user profiles from IBMi machine, but due to *ALLOBJ, this user profile may have access to few other commands -

Perform Read only operations.
Add or Remove User to an Authorization List.
Revoke Object Authority.
Change own password i.e. Self password change.
I want restrict all these command to execute on IBMi machine.

My main requirement is to create a user having very minimum permissions means who can only read data from IBMi machine and do not have capability to change any thing.

If any one is having any idea about this please share.
0
I research the official document about commands RCVJRNE and QSNDDTAQ in the IBM knowledge center. But I just find the introduce about the parameter.
The example is just simple and doesn't contain that send data to data queue using RCVJRNE. So please help me.
The follow is the RPG file.
     DDQNAME           S             10A   INZ('DTAQTEST')
     DDQLIB            S             10A   INZ('xxxxxxxxx')
     DDQSNDLEN         S              5  0 INZ(100)
     DDATLEN           S              3  0 INZ(0)
     DDATKEY           S             10A
     DASYREQ           S             10A   INZ('*NO')
     DDATJRN           S             10A   INZ('*YES')
     DDQSNDDATA        S            100A
     D*
     DDQLEN            S              5  0
     DDQTYPE           S              1A
     D*
     C*************************************
     C* Main Logic
     C*************************************
     C*
     C     *ENTRY        PLIST
     C                   PARM                    DQSNDDATA
     C                   PARM                    DQTYPE
     C
     C                   CALL      'QSNDDTAQ'
     C                   PARM                    DQNAME
     C                   PARM                    DQLIB
     C                   PARM                    DQSNDLEN
     C                   PARM                    DQSNDDATA
     C                   PARM                    DATLEN
     C                   PARM                    DATKEY
     C                   PARM         

Open in new window

0

IBM System i

IBM i, formerly known as AS/400, is a proprietary, midrange, object-based operating and application system. It includes a relational database, a menu-driven interface, support for multiple users, block-oriented terminal support and printers, and supports security, communications, and web-based application servers including Websphere, Apache and Tomcat.

Top Experts In
IBM System i
<
Monthly
>