aaahhh...
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Rajesh Choudhary
Sent: Monday, March 31, 2008 9:54 AM
To: RPG programming on the AS400 / iSeries
Subject: RE: Rép. : Classic Traps -- I need your input!
Because, by default, if you do not specify the datatype, numeric variables of the Data Structures are declared as zoned, in contrast to the standalone numeric variables, which are by default packed.
Also, (Trap) if you use Like keyword, specifying a field that was defined as zoned in PF, the field being defined gets declared as packed in rpg.
Regards,
Rajesh Choudhary | Software Engineer,
Manhattan Associates
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Lim Hock-Chai
Sent: Monday, March 31, 2008 8:00 PM
To: RPG programming on the AS400 / iSeries
Subject: RE: Rép. : Classic Traps -- I need your input!
Denis:
I'm not sure why making a variable become part of the data structure would change its attribute from packed to zoned.
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Denis Robitaille
Sent: Monday, March 31, 2008 7:35 AM
To: RPG programming on the AS400 / iSeries
Subject: Rép. : Classic Traps -- I need your input!
<clip>
2. AN RPG programs works fine, you decide to make a variable that is part of the parameters list part of a data structure. The variable was defined as packed. After being added to the array, it is now zoned!!
Your programs start to bomb because it receives bad input. To avoid it, what we did here is to avoied packed variable all together. The performance impact, if any, is negligeible.
</clip>
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list To post a message email: RPG400-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit:
http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives at
http://archive.midrange.com/rpg400-l.
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list To post a message email: RPG400-L@xxxxxxxxxxxx To subscribe, unsubscribe, or change list options,
visit:
http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives at
http://archive.midrange.com/rpg400-l.
As an Amazon Associate we earn from qualifying purchases.