|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Messageset for repeating fixed length elements without delim |
« View previous topic :: View next topic » |
Author |
Message
|
sorn73 |
Posted: Fri Feb 18, 2005 1:37 am Post subject: Messageset for repeating fixed length elements without delim |
|
|
Novice
Joined: 24 Mar 2004 Posts: 24 Location: Sweden
|
I trying to create a message set for a fixed-length field message that I will use with the MRM parser, both for parsing and serialising, but I'm having some problems.
The message consists of two elements of fixed length, A and B. The elements actually consist of several fixed length fields, so A and B are of complex types and has several fixed length string elements.
The layout of the message is ABBBBBBBBB..... . So A comes one time in the beginning and B comes one or more times after that. The problem is that there are no delimiters, not even CR LF, so I don't know what Data Element Separation to use on the B element type or the message type. Obviously, I cannot use Fixed Length, since that forces me to write out/parse all Max Occurences.
Any ideas? |
|
Back to top |
|
 |
PGoodhart |
Posted: Fri Feb 18, 2005 4:56 am Post subject: |
|
|
Master
Joined: 17 Jun 2004 Posts: 278 Location: Harrisburg PA
|
The best answer might be to see if you can put the data into a different format?
The structure you are describing sounds an lot like XML without the tags, or maybe you could get a deliminator added like a tab?
I without that you might be able to do something with the blob domain, by taking fixed length chunks and creating another messege but it is going to require some work. _________________ Patrick Goodhart
MQ Admin/Web Developer/Consultant
WebSphere Application Server Admin |
|
Back to top |
|
 |
sorn73 |
Posted: Fri Feb 18, 2005 7:25 am Post subject: |
|
|
Novice
Joined: 24 Mar 2004 Posts: 24 Location: Sweden
|
Yes, changing the dataformat would be the best solution, at least to add line delimiters. That is, however, currently not an option.
Also, building a BLOB parser in ESQL, even though it wouldn't be that hard, is also not a very appealing solution.
I did manage to make it work, but I'm not happy with the solution. I used "Use data pattern" as "Data Element Separation", and on the element(s) a "Regular Expression pattern" as .{20} to consume exactly 20 bytes, for example. I understand that this is resource intensive. But the data is, according to my specs, not that large. A better solution is welcome.
I think I understand why my previous attempt didn't work, from a purely academic viewpoint, but I don't see what's really different with this one. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|