(RPG) How to split a single download program in 2 programs?

Please do not use to report errors- use your regional help desk.
Please mark posts as being for RPG or RDMLX (LANSA) developer.
To subscribe by email, display this forum, scroll to the end and select ‘Subscribe Forum’.
Post Reply
LEBAS
Posts: 23
Joined: Fri May 11, 2012 5:02 pm

(RPG) How to split a single download program in 2 programs?

Post by LEBAS »

I’ve built one RPG program to download 3 tables: Deptments (table 1), Sections (table 2) and Employes (table 3): it works fine.

But now, I want to separate the Deptment/Section download process from the Employes download process. So, I’ve created 2 programs and deleted inside the corresponding unneeded lines:
- The Deptment/Section download works well.
- The Employes download does not work: [NullPointerException] error.

Has somebody already encounters this error?

I’ve attached the 3 programs.

Yann
Attachments
YLDWNEMP.txt
Download Employes
(3.42 KiB) Downloaded 284 times
YLDWNDEPSE.txt
Download Dept/section
(4.27 KiB) Downloaded 263 times
YLDOWNLOAD.txt
Download 3 tables
(6.38 KiB) Downloaded 270 times
tsupartono
Posts: 289
Joined: Wed Apr 18, 2012 10:21 am

Re: (RPG) How to split a single download program in 2 progra

Post by tsupartono »

Support will investigate this.
LEBAS
Posts: 23
Joined: Fri May 11, 2012 5:02 pm

Re: (RPG) How to split a single download program in 2 progra

Post by LEBAS »

To solve this, I need to use in my Employes download program:
LRNG_SetProperty( '/DB.Table%1' : 'Employes');
...
EZI_Offline_SendTableRow(
1 //Table number
: RowCountE
: 'EMPNO' : EMPNO
...

In each download program, you need to restart from 1 for table numbers. 'Table number' is not the internal number of the SQLite table: it is an internal number to the RPG program.

Thanks to Tony
Post Reply