Sunday, 14 January 2007

Hi

I was trying to help someone in the BizTalk newsgroups, creating a flat file schema, and I ran into this very annoying error message: "Unable to match the data in the input stream.". I got the error message after having created the schema and trying to validate an instance, using VS.NET 2005.

I searched and searched...

  • Someone needed to set the "parser_optimization" to "complexity" - I had allready done that.
  • Someone else needed to set the "lookahead_depth to 0 - I had also tried that.
  • Someone needed to set the input type to "Native" instead of XML. Had that been my problem, I wouldn't have blogged about it - I'd be too embarassed :-)

No, the problem was that I had created parts of the schema using the flat file wizard. It had set one of my records to have "minOccurs" = 18 and "maxOccurs" = 18 as well. Since my test instance didn't have that many records in it, I got this error message. Changing the two 18's to the default 1 solved my problem.

I hope Microsoft considers this and perhaps in future releases find a better error description :-)

In order to test it, you can just download the working schema: Exolit_FlatFileSchema.xsd (91.59 KB) and the test instance: Instance.txt (.72 KB) - it will validate. But try to change the minOccurs and maxOccures of the "Invoices"-record to "18" - and revalidate.

Anyway... Hope this helps someone in the future.

--
eliasen

Sunday, 14 January 2007 13:41:33 (Romance Standard Time, UTC+01:00)  #    Comments [3]  | 
Wednesday, 26 March 2008 17:27:58 (Romance Standard Time, UTC+01:00)
Even I also faced such a problem with a sap idoc schema.. got resolved by setting look ahead depth to 0.. Your artical was helpful to find out the possible causes.. :)

MS article on this..
http://support.microsoft.com/kb/884622
Friday, 04 June 2010 06:33:45 (Romance Daylight Time, UTC+02:00)
Sure as heck helped me! Mine put in minOccurs=6 and maxOccurs=6 for whatever reason. odd balls!
Friday, 04 June 2010 08:25:54 (Romance Daylight Time, UTC+02:00)
Hi

Glad I could help. Yes, very strange... but hey, many things are strange... :-)

--
eliasen
All comments require the approval of the site owner before being displayed.
OpenID
Please login with either your OpenID above, or your details below.
Name
E-mail
Home page

Comment (Some html is allowed: a@href@title, b, blockquote@cite, em, i, strike, strong, sub, sup, u) where the @ means "attribute." For example, you can use <a href="" title=""> or <blockquote cite="Scott">.  

Enter the code shown (prevents robots):

Live Comment Preview

Theme design by Jelle Druyts