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 » parsing error during TDS of csv file

Post new topic  Reply to topic
 parsing error during TDS of csv file « View previous topic :: View next topic » 
Author Message
adars1
PostPosted: Fri Apr 01, 2011 2:40 pm    Post subject: parsing error during TDS of csv file Reply with quote

Apprentice

Joined: 13 Jun 2010
Posts: 39

Hi,

Iam using csv file for fileinput node to parse the incoming file.
each line is treated as one record and each record is delimited by ,

if my file input line is like:
87044444,KJUL,0,2,"have been sent package on (03.15 03.16), campaign LL"
then it parses fine.
if the input line is like:
87023333,IJKL,0,2,"have been sent package on (03.15 03.16), campaign LL",
Iam getting error:
<Error><FlowName>Inbound</FlowName><TimeStamp>2011-04-01 16:58:05.994420</Ti
meStamp><ErrorDetail><RecoverableException><File>/build/S610_P/src/DataFlowEngin
e/ImbTraceNode.cpp</File><Line>341</Line><Function>ImbTraceNode::evaluate</Funct
ion><Type>ComIbmTraceNode</Type><Name>Inbound#FCMComposite_1_14</Name><Label
>Inbound.Trace1</Label><Catalog>BIPv610</Catalog><Severity>3</Severity><Numb
er>2230</Number><Text>Caught exception and rethrowing</Text><ParserException><Fi
le>/build/S610_P/src/MTI/MTIforBroker/MtiImbParser2/MtiImbParser.cpp</File><Line
>509</Line><Function>MtiImbParser::parseFirstChild</Function><Type>ComIbmFileInp
utNode</Type><Name>Inbound#FCMComposite_1_1</Name><Label>Inbound.CCHGI
N</Label><Catalog>BIPv610</Catalog><Severity>3</Severity><Number>5285</Number><T
ext>ImbRecoverableException caught from worker->parseNext.</Text><Insert><Typ
e>5</Type><Text>ICUMsgSet</Text></Insert><Insert><Type>2</Type><Text>1</Text></I
nsert><Insert><Type>5</Type><Text>Text1</Text></Insert><Insert><Type>5</Type><Te
xt>/msg_INBOUND/NEWVAL</Text></Insert><ParserException><File>/build/S610_P/s
rc/cpi/pwf/nxd/nxdworker.cpp</File><Line>462</Line><Function>NXDWorker::parseNex
t</Function><Type></Type><Name></Name><Label></Label><Catalog>BIPv610</Catalog><
Severity>1</Severity><Number>5421</Number><Text>TDS General Error</Text><Insert>
<Type>5</Type><Text>msg_INBOUND</Text></Insert><Insert><Type>5</Type><Text>/
msg_INBOUND/NOTE</Text></Insert><Insert><Type>2</Type><Text>21</Text></Inser
t><ParserException><File>/build/S610_P/src/cpi/pwf/nxd/nxdterminatingmarkupmatch
er.cpp</File><Line>341</Line><Function>NXDTerminatingMarkupMatcher::identifyMark
up</Function><Type></Type><Name></Name><Label></Label><Catalog>BIPv610</Catalog>
<Severity>3</Severity><Number>5627</Number><Text>Quote character is not allowed
in this position</Text><Insert><Type>5</Type><Text>"</Text></Insert><Insert
><Type>2</Type><Text>136</Text></Insert></ParserException></ParserException></Pa
rserException></RecoverableException></ErrorDetail></Error>

only difference between 2 lines is , at the end of 2nd line.
Back to top
View user's profile Send private message
kimbert
PostPosted: Fri Apr 01, 2011 3:26 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

a) You have not described your message model. Are you using the model provided in the CSV sample?
b) Did you set a delimiter on the FileInput node? Or are you passing the entire file to the message flow, and letting the TDS parser split it into records?
Back to top
View user's profile Send private message
adars1
PostPosted: Mon Apr 04, 2011 5:16 am    Post subject: Reply with quote

Apprentice

Joined: 13 Jun 2010
Posts: 39

- using the MRM parser and defined the msgset with TDS delimiter ,
- splitting the file at file input node through end of line
Back to top
View user's profile Send private message
kimbert
PostPosted: Mon Apr 04, 2011 5:45 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
using the MRM parser and defined the msgset with TDS delimiter ,
Your input file uses quote characters to allow commas and line feeds within a field. Does your MRM message set cope with that?
Quote:
splitting the file at file input node through end of line
Please can you take a debug-level user trace and post the relevant part here. You will need to run the following commands in the following order:
- mqsichangetrace
- mqsireadlog
- mqsiformatlog

One possibility is that you are actually passing the entire file to the TDS parser. So maybe the first thing you should do is check that you have specified the line feed character correctly in the FileInput node.
Back to top
View user's profile Send private message
adars1
PostPosted: Mon Apr 04, 2011 6:36 am    Post subject: Reply with quote

Apprentice

Joined: 13 Jun 2010
Posts: 39

- in input file node, iam splitting records by delimited dos or unix line end.
- after this node Iam using ResetContentDescriptor node to parse the each record with MRM parser and using the msgset properties to split the record using delimiter '.
-msgset msg format :
Data Element seperation: All Elements Delimited
Delimiter: ,
Back to top
View user's profile Send private message
kimbert
PostPosted: Mon Apr 04, 2011 6:44 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
Does your MRM message set cope with that?
I'll answer my own question: I think you're OK, because you would not have got error message ( BIP5627 ) if you had not set up your quoting style to follow CSV rules.

So...what about my other questions?
Back to top
View user's profile Send private message
adars1
PostPosted: Fri Apr 08, 2011 9:14 am    Post subject: Reply with quote

Apprentice

Joined: 13 Jun 2010
Posts: 39

Andalso the msgset complex type physical property 'Suppress Absent Element Delimiters' is 'Never'. IBM support suggested to use 'End of Type', but it will create other problems of not validating the previous missing fields.
I did take trace debug, but it is big enough to post it here.
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 » parsing error during TDS of csv file
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.