|
Brian, this kind of makes sense to me, but unfortunately the data structure is not the entire record format of the file, nor is the field order the same. I have meanwhile added a workfield for the prototyped call, and now it works just fine. Thanks anyway, Peter Colpaert Application Developer Massive - Kontich, Belgium ----- Real programmers never document. If it was hard to write, it should be hard to understand. ----- Brian Parkins <parkib@xxxxxxxxxx> Sent by: rpg400-l-bounces@xxxxxxxxxxxx 03/11/2004 12:54 Please respond to RPG programming on the AS400 / iSeries To: RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx> cc: Subject: Re: Field shows as packed and zoned I think you will find this is working-as-designed. Because you have placed the Packed Decimal field in a (non-external) Data Structure, you are effectively re-defining the variable. The default numeric type is Zoned Decimal for a Data Structure subfield. Try this: DDS FOR MYFILE A R MYFMT A PACKED 2P 0 A ZONED 2S 0 A CHARACTER 2A RPG FOR MYPGM FMyFile IF E Disk D FileDS DS D Packed Inz D Zoned Inz D Character Inz /Free Dsply Packed '*REQUESTER'; *InLR = *on; /End-Free COMPILER X-REF LIST (IGNORE THE I-SPECS) Global Field References: Field Attributes References (D=Defined M=Modified) *INLR N(1) 16M *RNF7031 CHARACTER A(2) 7D 14D *RNF7031 FILEDS DS(6) 4D PACKED S(2,0) 5D 12D 15 <<<<<<< *RNF7031 ZONED S(2,0) 6D 13D To preserve the Data Type as Packed, define as an externally (E) defined Data Structure. Brian Parkins -- 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.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.