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 » Detecting parse Exception point in a MRM

Post new topic  Reply to topic
 Detecting parse Exception point in a MRM « View previous topic :: View next topic » 
Author Message
giorginus80
PostPosted: Wed Dec 31, 2008 1:41 am    Post subject: Detecting parse Exception point in a MRM Reply with quote

Centurion

Joined: 08 Jul 2008
Posts: 124
Location: Rome, Italy

Hi, I have a plain text delimited file, I parse it with the mrm definition with mxsd. I can't find when I have a malformed file, the point where the file is wrong.
Another question, when I parse it from BLOB, I use an ESQL node
Code:

      DECLARE parseOptions INTEGER BITOR(FolderBitStream, ValidateContent,
      ValidateValue, ValidateLocalError);
      
      DECLARE creationPtr REFERENCE TO OutputRoot.MRM;
      CREATE LASTCHILD OF creationPtr DOMAIN('MRM')
      PARSE(InputRoot.BLOB.BLOB
      OPTIONS parseOptions
      SET 'SirSet'
      TYPE 'rispostaSir'
      FORMAT 'XML1');      


How can I pass to option to don't validate the mxsd (I need in this point of the flow to don't validate min or max occurences of the fields defined in the mxsd)
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Dec 31, 2008 3:12 am    Post subject: Re: Detecting parse Exception point in a MRM Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

giorginus80 wrote:
Hi, I have a plain text delimited file, I parse it with the mrm definition with mxsd. I can't find when I have a malformed file, the point where the file is wrong.
Another question, when I parse it from BLOB, I use an ESQL node
Code:

      DECLARE parseOptions INTEGER BITOR(FolderBitStream, ValidateContent,
      ValidateValue, ValidateLocalError);
      
      DECLARE creationPtr REFERENCE TO OutputRoot.MRM;
      CREATE LASTCHILD OF creationPtr DOMAIN('MRM')
      PARSE(InputRoot.BLOB.BLOB
      OPTIONS parseOptions
      SET 'SirSet'
      TYPE 'rispostaSir'
      FORMAT 'XML1');      


How can I pass to option to don't validate the mxsd (I need in this point of the flow to don't validate min or max occurences of the fields defined in the mxsd)

You say you have a plain text delimited file, yet when you parse from BLOB you declare the format as 'XML1'? Shouldn't the format be 'TDS1' ?

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
giorginus80
PostPosted: Wed Dec 31, 2008 3:18 am    Post subject: Re: Detecting parse Exception point in a MRM Reply with quote

Centurion

Joined: 08 Jul 2008
Posts: 124
Location: Rome, Italy

fjb_saper wrote:
giorginus80 wrote:
Hi, I have a plain text delimited file, I parse it with the mrm definition with mxsd. I can't find when I have a malformed file, the point where the file is wrong.
Another question, when I parse it from BLOB, I use an ESQL node
Code:

      DECLARE parseOptions INTEGER BITOR(FolderBitStream, ValidateContent,
      ValidateValue, ValidateLocalError);
      
      DECLARE creationPtr REFERENCE TO OutputRoot.MRM;
      CREATE LASTCHILD OF creationPtr DOMAIN('MRM')
      PARSE(InputRoot.BLOB.BLOB
      OPTIONS parseOptions
      SET 'SirSet'
      TYPE 'rispostaSir'
      FORMAT 'XML1');      


How can I pass to option to don't validate the mxsd (I need in this point of the flow to don't validate min or max occurences of the fields defined in the mxsd)

You say you have a plain text delimited file, yet when you parse from BLOB you declare the format as 'XML1'? Shouldn't the format be 'TDS1' ?

Have fun

Sorry I put wrong code...yes the Format is CSV1, I want to convert it in mrm, it works all good, I just want to detect a possible exception point, if the file is malformed (like unconvertable character on a point and so on) how can I detect the point of Exception? thanks in advance
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Dec 31, 2008 3:23 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Map to a trace node and output the exception tree and the message tree.
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
giorginus80
PostPosted: Wed Dec 31, 2008 3:26 am    Post subject: Reply with quote

Centurion

Joined: 08 Jul 2008
Posts: 124
Location: Rome, Italy

fjb_saper wrote:
Map to a trace node and output the exception tree and the message tree.


ok I try to see if there is in the exception tree the exact point of the error in the file! thanks
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Jan 01, 2009 4:09 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
Hi, I have a plain text delimited file, I parse it with the mrm definition with mxsd. I can't find when I have a malformed file, the point where the file is wrong.
So...you are using MRM TDS, and you have a problem. First step is to take a user trace. If you are on v6.1, it will show you exactly what the TDS parser is doing. On other versions of the product it will still provide the full text of all errors, and the context in which they occurred.
Quote:
(I need in this point of the flow to don't validate min or max occurences of the fields defined in the mxsd)
In that case, you should ask yourself whether you really need validation enabled. It checks things like min/max Occurs, missing fields etc. It also checks MRM value constraints ( same as schema facets ). But you probably don't need min/maxOccurs validation, and you don't want facet validation. Checking for invalid characters will happen even if validation is disabled.
Quote:
I just want to detect a possible exception point, if the file is malformed (like unconvertable character on a point and so on) how can I detect the point of Exception?
User Trace.
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 » Detecting parse Exception point in a MRM
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.