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 » Multiline record MRM parsing

Post new topic  Reply to topic
 Multiline record MRM parsing « View previous topic :: View next topic » 
Author Message
aq
PostPosted: Mon Sep 13, 2004 8:51 am    Post subject: Multiline record MRM parsing Reply with quote

Apprentice

Joined: 20 Dec 2001
Posts: 47

Hi

I have tough question about the MRM parsing (tough atleast for me).

We receive message that contains multiple orders. Each order has:

- 1 header (1 line)
- 1 or more products (1 .. * lines)
- 0 to 1 additional details / instructions (0 or 1 line)

Each line contains record that is only part of the order. Record type (HEADER, PRODUCT, DETAILS) is told by first item in record. Second item in each record is order id (1000, 1001, 1002, 1003) and tells to what order this line belongs (grouping factor for single order).

Items in record are separated by ',' delimeter + are fixed length.

Is it possible parse this kind of data (look example data) to tree like structure (look example MRM tree) by just using the MRM parsing ? (and if yes how ???)


== EXAMPLE DATA =================

HEADER,1000,2004-09-03
HEADER,1001,2004-09-08
HEADER,1002,2004-09-08
HEADER,1003,2004-09-13
PRODUCT,1000,1,Apples
PRODUCT,1000,2,contact admin
DETAILS,1000,Your apples are so good.
PRODUCT,1001,1,Apples
PRODUCT,1001,3,Oranges
PRODUCT,1001,4,contact admin
PRODUCT,1002,3,Oranges
PRODUCT,1003,2,contact admin
PRODUCT,1003,4,contact admin
DETAILS,1003,Please deliver them fast !

=================================


== EXAMPLE MRM TREE =============

Orders
|
|
- Order
|
- product (Apples)
|
- product (Banana)
|
- id (1000)
|
- date (2004-09-03)
|
- details (Your apples are so good.)
|
|
- Order
|
- product (Apples)
|
- product (Oranges)
|
- product (contact admin)
|
- id (1001)
|
- date (2004-09-08)
|
|
- Order
|
- product (Oranges)
|
- id (1002)
|
- date (2004-09-08)
|
|
- Order
|
- product (contact admin)
|
- product (contact admin)
|
- id (1003)
|
- date (2004-09-13)
|
- details (Please deliver them fast !)

=================================

Very much thanks for answers !


Regards,
a
Back to top
View user's profile Send private message
Ramphart
PostPosted: Mon Sep 13, 2004 9:19 am    Post subject: Reply with quote

Disciple

Joined: 21 Jul 2004
Posts: 150
Location: South Africa, JHB

See if the link below is helpful.

http://www.mqseries.net/phpBB2/viewtopic.php?t=16843&highlight=
_________________
Applications Architect
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Sep 13, 2004 9:42 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Yeah, this is a basic tagged/delimited message.

But you won't get the kind of tree you want - not unless you sort your data by the order number first.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
aq
PostPosted: Wed Sep 15, 2004 12:29 am    Post subject: Reply with quote

Apprentice

Joined: 20 Dec 2001
Posts: 47

The link was very helpful.

Guess I have to do some ESQL "preparsing / sorting" for data, but oh well cannot have everything (it just would have been nice).

Thanks for you answers !
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 » Multiline record MRM parsing
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.