IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

XML Generate - suppression of complex nodes


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
jzhardy

Active User


Joined: 31 Oct 2006
Posts: 144
Location: brisbane

PostPosted: Thu May 22, 2025 7:03 am
Reply with quote

hi all,

I have a structure such as the following:
Code:

   03 WS-XML-0174-09-X OCCURS 99 TIMES DEPENDING ON WS-XML-0174-09-SIZE.  *>OC_DTLS
      05 WS-017400820-07  PIC X(0255).  *>SUB_ACC_TTL
      05 WS-017400820-08  PIC X(0016).  *>SUB_ACC_STRT_BAL
      05 WS-017400820-14  PIC X(0016).  *>SUB_ACC_END_BAL
      05 WS-XML-0174-10.   *> SA_DTLS
         07 WS-017400820-09  PIC X(0010).  *>SA_DTL_ITM_DATE
         07 WS-017400820-10  PIC X(0255).  *>SA_DTL_ITM_DES
         07 WS-017400820-11  PIC X(0016).  *>SA_DTL_CRDT_AMT
         07 WS-017400820-12  PIC X(0016).  *>SA_DTL_DBT_AMT
         07 WS-017400820-13  PIC X(0016).  *>SA_DTL_ITEM_BAL
      05 WS-017400820-15  PIC X(0001).  *>LATE_PNLTY_IND


I can suppress everything under WS-XML-0174-09-X using a phrase like :
Code:
SUPPRESS WS-XML-0174-09-X EVERY ELEMENT WHEN SPACES OR ZERO
                          EVERY CONTENT WHEN SPACES OR ZERO


If everything under WS-XML-0174-09-X ends up being suppressed, then WS-XML-0174-09-X (which is named "OC_DTLS") is retained, meaning I end up with :
Code:
<OC_DTLS></OC_DTLS>


Is there a way I can suppress element WS-XML-0174-09-X (OC_DTLS) in this situation ?
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Sort card to generate the DSN DFSORT/ICETOOL 17
No new posts XML Generate issue COBOL Programming 0
No new posts Save SYSLOG in a MASS complex All Other Mainframe Topics 3
No new posts What is the most complex abend you've... Mainframe Interview Questions 8
No new posts Generate random number from range of ... COBOL Programming 3
Search our Forums:


Back to Top