From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.182.70.68 with SMTP id k4mr4982381obu.9.1431080414306; Fri, 08 May 2015 03:20:14 -0700 (PDT) X-Received: by 10.50.152.102 with SMTP id ux6mr57738igb.0.1431080414237; Fri, 08 May 2015 03:20:14 -0700 (PDT) Path: border1.nntp.dca1.giganews.com!nntp.giganews.com!m20no312505iga.0!news-out.google.com!n7ni27854igk.0!nntp.google.com!m20no312498iga.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 8 May 2015 03:20:13 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=116.74.2.27; posting-account=l8G6hgoAAADjKtWjPGHyywkx7knGLmuP NNTP-Posting-Host: 116.74.2.27 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <46ce5d86-b624-4a96-8f12-c28e3a3ffd9f@googlegroups.com> Subject: Re: Validating XML using Ada schema module From: Sonia Dalal Injection-Date: Fri, 08 May 2015 10:20:14 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Xref: number.nntp.giganews.com comp.lang.ada:193082 Date: 2015-05-08T03:20:13-07:00 List-Id: On Thursday, May 7, 2015 at 9:23:22 PM UTC+5:30, Sonia Dalal wrote: > Hi all >=20 > I am new to ada. I am working on a project where I am parsing XML for dat= a. I am trying to validate the XML received (I am receiving XML from third = party) using the schema module. Following is the sample schema which I took= from w3c site after I was getting raised CONSTRAINT_ERROR : schema-validat= ors.adb:2166 invalid data for my own schema but I am getting same error for= this schema. >=20 > >=20 > >=20 > > > > > > > > > > >=20 > >=20 > Changing the version and scheam tag to=20 > >=20 > elementFormDefault=3D"qualified" > targetNamespace=3D"http://example.com/schemas/agent" > xmlns:agent=3D"http://example.com/schemas/agent">=20 >=20 > does not make any difference. I tried looking into schema-validators.adb = but that was of no use. Please help. The above code is what I have used in my xsd and I am following the Ada doc= umentation to generate grammar.=20 I have put my xsd code aside just to figure out what is the reason for erro= r as it is same in both the scenarios. I am using GNAT 4.6 so it should be Ada 2005. Is it possible that it is due to some dependency or version clashes?