Author |
Message
|
atul_jain1981 |
Posted: Sun Apr 27, 2008 10:19 am Post subject: Spiltting Recrods in FileInput Node |
|
|
Novice
Joined: 27 Apr 2008 Posts: 10
|
Hi
I am using FileInput Node for file parsing and spiltting.
I am having a TDS file with multiple records. and I have made
a msg set for the schema of file and assigned it for parsing to
FileInput node.
I want all the records in file to move as a seperate msg to MQOUTPUT node. I have set "parsed record sequence" for the same.
My file is getting parsed sucessfully by Parser ,and message tree is getting generated ...but I am getting a single message in mq which is
containing whole file.
Please suggest me where I m wrong in the same ?
- Atul |
|
Back to top |
|
 |
Vitor |
Posted: Sun Apr 27, 2008 10:36 am Post subject: Re: Spiltting Recrods in FileInput Node |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
atul_jain1981 wrote: |
My file is getting parsed sucessfully by Parser ,and message tree is getting generated ...but I am getting a single message in mq which is
containing whole file.
Please suggest me where I m wrong in the same ?
|
Split up the message tree using a Compute Node (fairly straightforward if the message set is already parsed) and PROPOGATE the individual messages.
This has been discussed a few times in here - The Search Facility Is Your Friend _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
jefflowrey |
Posted: Sun Apr 27, 2008 11:41 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You need to tell the FileInput node what a single record looks like, not a message full of many records. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
kimbert |
Posted: Sun Apr 27, 2008 12:06 pm Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Quote: |
I am getting a single message in mq which is
containing whole file |
There are two possibilities here:
a) your message model is correct for a single message, but not for a stream of messages. Maybe it relies on the end of the bitstream to terminate an individual message, which is not going to work for a file containing multiple messages
b) your message style cannot be reliably parsed from a stream of messages because the parser must rely on the end of the bitstream.
I would need a lot of detail about the message format to decide which of these applies to you.
Quote: |
Please suggest me where I m wrong in the same |
User Trace contains messages which tell you the TDS parser is doing. I hope you have already tried that  |
|
Back to top |
|
 |
atul_jain1981 |
Posted: Sun Apr 27, 2008 9:27 pm Post subject: Split up the message tree using a Compute Node |
|
|
Novice
Joined: 27 Apr 2008 Posts: 10
|
Ya splitting the message through compute node is poosible , but as the documentation for meesge broker says in topic
"Reading a file, effects of different values in the FileInput node's Record detection property "
That we can do in at file input node it self.
In that topic in message broker help seach:
Example 6. Records read are recognized as separate messages by the parser specified in the Message domain property
So if we can do it at FIleInput node end... then why we need to add one more node for the same.
Please suggest me if I m wrong....or wht is the correct way of doing the same.
Thanks in advace |
|
Back to top |
|
 |
kimbert |
Posted: Mon Apr 28, 2008 12:21 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
vitor's suggestion is correct for v6.0, and it will still work in v6.1. However, the 'Parsed Record Sequence' property ( or whatever it's called ) was added in v6.1 to automate that process. IF it is possible to do it using on-demand parsing / Compute node then it should be possible to do it using the standard facilities in the FileInput node.
Whichever method you choose, you have to get the message model right. And sometimes, no model will work because the message format is not parseable as part of a stream ( in which case you need the message length or a delimiter ). |
|
Back to top |
|
 |
Vitor |
Posted: Mon Apr 28, 2008 12:28 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
kimbert wrote: |
vitor's suggestion is correct for v6.0, and it will still work in v6.1. |
I have so got to get me some v6.1 time!!  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
atul_jain1981 |
Posted: Mon Apr 28, 2008 1:14 am Post subject: |
|
|
Novice
Joined: 27 Apr 2008 Posts: 10
|
hey kimbert
Thanks for repling....
But my issue is still unresolved...and i m seeking for help on the same
that how to use FileInput Node for the same.
 |
|
Back to top |
|
 |
rakesh567 |
Posted: Mon Apr 28, 2008 2:35 am Post subject: |
|
|
Novice
Joined: 26 Jan 2008 Posts: 18
|
Record elements you use as delimiter.
Update the transaction mode accordingly. |
|
Back to top |
|
 |
kimbert |
Posted: Mon Apr 28, 2008 5:03 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Quote: |
I would need a lot of detail about the message format to decide which of these applies to you. |
...I'm waiting
rakesh567: I did not understand your post. Please explain your point. |
|
Back to top |
|
 |
atul_jain1981 |
Posted: Mon Apr 28, 2008 7:44 am Post subject: |
|
|
Novice
Joined: 27 Apr 2008 Posts: 10
|
Hey Rakesh
As i mentioned previously my records are getting parsed properly
and i m getting required message tree in trace.
I am working in transaction mode wiht ON Demand Parsing and
record parsed sequence.
I can see individual records in trace but they are coming out of FileInput node as a single messge i.e. whole File but i want them to come as individual message.
any one who worked on this kind of requirement plz help
 |
|
Back to top |
|
 |
kimbert |
Posted: Mon Apr 28, 2008 9:40 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Quote: |
my records are getting parsed properly |
I suspect that they are not. Read on for the reason why...
Quote: |
I can see individual records in trace but they are coming out of FileInput node as a single messge |
They are coming out as a single message because the TDS parser thinks that the entire file is one message. Your message definition is allowing that to happen. You need to change your message definition to stop that from happening.
I can't tell you how to do that because you have not described your message format. |
|
Back to top |
|
 |
|