Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

XML GENERATE with empty occurs

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
grabeva

New User


Joined: 07 Sep 2006
Posts: 23

PostPosted: Fri Apr 18, 2008 10:52 pm    Post subject: XML GENERATE with empty occurs
Reply with quote

HI,

i have this copy and i want to generate an xml code.
the compiler not allow me to replace the second occurs, for
"occurs depending on", and i put an occurs of 70 times.
Some times, this occurs appear empty, and i don't want to transmit
xml empty occurs. How I do it?

Tks...for your time.
Gra

de value of occurrency, of second OCCURS are in field: NoMov

05 Response.
07 Request PIC 9(4).
07 ResponseCode PIC 9(04).
07 NoTx PIC 9(04).
07 Brancx PIC X(25).
07 LastOper PIC X(10).
07 Name PIC X(30).
07 Currencx PIC X(03).
07 CloseBalanceDate PIC 9(08).
07 LastCloseBalance PIC S9(16)V99.
07 MoreTxKex PIC x(66).
07 Responset.
10 TX-DAY OCCURS 0 to 70 TIMES depending on numitem.
12 Datx PIC 9(08).
12 DailyOpenBalance PIC S9(16)V99.
12 DailyCloseBalance PIC S9(16)V99.
12 NoMov PIC 9(04).
12 Tx OCCURS 70 TIMES
14 TransCheq-RF PIC x(20).
14 TranReference PIC x(20).
14 TranDate PIC 9(08).
14 TranCode PIC 9(03).
14 TranAmount PIC S9(16)V99.
14 TransNroEF PIC x(10).
14 TransDesc PIC x(50).
Back to top
View user's profile Send private message

CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Fri Apr 18, 2008 11:00 pm    Post subject:
Reply with quote

The only way I can see is to have a second definition, with Responset omited or defined as an elementary item....
Back to top
View user's profile Send private message
grabeva

New User


Joined: 07 Sep 2006
Posts: 23

PostPosted: Fri Apr 18, 2008 11:22 pm    Post subject: Reply to: XML GENERATE with empty occurs
Reply with quote

Sorry Guy,

can you explain me? i don't understand.
TKS
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Sat Apr 19, 2008 12:01 am    Post subject: Re: XML GENERATE with empty occurs
Reply with quote

Code:
         01 Long-XML.
          05 Response.
            07 Request                 PIC  9(4).
            07 ResponseCode            PIC  9(04).
            07 NoTx                    PIC  9(04).
            07 Brancx                  PIC  X(25).
            07 LastOper                PIC  X(10).
            07 Name                    PIC  X(30).
            07 Currencx                PIC  X(03).
            07 CloseBalanceDate        PIC  9(08).
            07 LastCloseBalance        PIC  S9(16)V99.
            07 MoreTxKex               PIC  x(66).
            07 Responset.
              10 TX-DAY OCCURS 0 to 70 TIMES depending on numitem.
                 12 Datx                 PIC  9(08).
                 12 DailyOpenBalance     PIC  S9(16)V99.
                 12 DailyCloseBalance    PIC  S9(16)V99.
                 12 NoMov                PIC  9(04).
                 12 Tx OCCURS 70 TIMES
                   14 TransCheq-RF       PIC  x(20).
                   14 TranReference      PIC  x(20).
                   14 TranDate           PIC  9(08).
                   14 TranCode           PIC  9(03).
                   14 TranAmount         PIC  S9(16)V99.
                   14 TransNroEF         PIC  x(10).
                   14 TransDesc          PIC  x(50).
         01 Short-XML.
          05 Response.
            07 Request                 PIC  9(4).
            07 ResponseCode            PIC  9(04).
            07 NoTx                    PIC  9(04).
            07 Brancx                  PIC  X(25).
            07 LastOper                PIC  X(10).
            07 Name                    PIC  X(30).
            07 Currencx                PIC  X(03).
            07 CloseBalanceDate        PIC  9(08).
            07 LastCloseBalance        PIC  S9(16)V99.
            07 MoreTxKex               PIC  x(66).
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Generate Cohort report using SORT Indrajit_57 SYNCSORT 6 Wed Jun 01, 2016 9:41 am
This topic is locked: you cannot edit posts or make replies. how to find if file is empty or not. abdulrafi DFSORT/ICETOOL 5 Tue May 17, 2016 4:39 pm
No new posts How to map virtual printer in JCL, to... user_22 JCL & VSAM 6 Fri Apr 15, 2016 10:04 pm
No new posts Generate a JCL using REXX spoorni CLIST & REXX 3 Sat Feb 06, 2016 6:45 am
No new posts Any example of XML GENERATE nested st... marianambot COBOL Programming 6 Tue Sep 22, 2015 7:48 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us