ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Doubts about parsing... the message

Post new topic  Reply to topic
 Doubts about parsing... the message « View previous topic :: View next topic » 
Author Message
547c547
PostPosted: Mon Oct 13, 2014 2:12 am    Post subject: Doubts about parsing... the message Reply with quote

Acolyte

Joined: 16 Jun 2014
Posts: 51

Code:
01 CGSI1120-COPY.
         02 MESSAGE-HOLDER.
               03 RECORD-ID               PIC X(4).  << --  Imaginary element
            03 CUSTOMER  OCCURS 1 TIMES.
              04 FILE                       PIC X(4).
              04 SENDER                    PIC X(5).
              04  RECEIVER                  PIC X(5).
              04  FILE-ID                   PIC X(8).
              04 PROCESS-1                 PIC X(6).
              04  DATA                     PIC X(6).
              04 LENGTH                    PIC X(5).
              04  PROCESS-2                 PIC X(6).
              04 ROCESS-3                 PIC X(6).
              04 FILLER                         PIC X(99).
            03 BODY-01 OCCURS 1 TIMES.
              04 REC-TP                         PIC X(1).
              04 RWS-NUM                        PIC X(8).
              04 VND-PO-NUM                     PIC X(16).
              04 INBD-DELY-DOC-NUM              PIC X(16).
              04 TRX-DT                         PIC X(8).
              04 GOODS-MOVE-CD                  PIC X(2).
              04 FILLER-1                       PIC X(99).
              04 BODY-03 OCCURS 999 TIMES.
                05 R1                        PIC X(1).
                05 R NUM                        PIC X(8).
                05 R-LINE                PIC X(3).
                05  CD                        PIC X(16).
                05  CN -CD              PIC X(5).
                05 LOC-CD                    PIC X(4).
                05 BATCH                    PIC X(10).
                05  TP-CD                     PIC X(3).
                05  QTY                        PIC 9(10).
                05 UOM-CD                     PIC X(4).
                05  ITEM-NUM           PIC X(4).
                05 FILLER-2                       PIC X(82).
            03  TRAILER OCCURS 1 TIMES.
              04 FILE                       PIC X(4).
              04 SENDER                    PIC X(5).
              04  RECEIVER                  PIC X(5).
              04  FILE-ID                   PIC X(8).
              04 PROCESS-1                 PIC X(6).
              04  DATA                     PIC X(6).
              04 LENGTH                    PIC X(5).
              04  PROCESS-2                 PIC X(6).
              04 PROCESS-3                 PIC X(6).
              04 FILLER                         PIC X(99).


this is the cobol file I am trying to build a message definition TO parse.. using multipart message technique..

Question :: Can I take an imaginary element as record id since I didnt find any common one??

2) Body has sub-part BODY-03, CAN I delete that and take as outer message..??

Please answer.. Will be waiting for your valuable suggestions?
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Oct 14, 2014 3:25 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Help me out...what is an 'imaginary element'?
_________________
Before you criticize someone, walk a mile in their shoes. That way you're a mile away, and you have their shoes too.
Back to top
View user's profile Send private message
547c547
PostPosted: Tue Oct 14, 2014 7:57 pm    Post subject: Reply with quote

Acolyte

Joined: 16 Jun 2014
Posts: 51

I mean.. Since I didnt find any common element(in provided requirement) to place it as record id.. I took an imaginary element .. changed it intercept value as Message Identity
Back to top
View user's profile Send private message
mqjeff
PostPosted: Wed Oct 15, 2014 5:04 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

It's only an imaginary element if you do not put it into the message model.

Once it's in the message model, it's a real element (well, depending on data type it might be an integral element).

Yes, you can alter a message model after building it from a copybook or other kind of imported data structure.

At some point, the message model you are using to create or parse a message has to actually completely match the data being sent or received by the external application.
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Oct 16, 2014 6:44 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Yes, you can have more than one element with 'Interpret element value' set to 'Message identity'. The parser will use the value of the most recently-encountered 'message identity' element when it resolves an embedded message.
_________________
Before you criticize someone, walk a mile in their shoes. That way you're a mile away, and you have their shoes too.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Doubts about parsing... the message
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.