[DDC-2431] XML Not parsed Created: 05/May/13  Updated: 09/May/13  Resolved: 09/May/13

Status: Resolved
Project: Doctrine 2 - ORM
Component/s: ORM
Affects Version/s: 2.2
Fix Version/s: None
Security Level: All

Type: Bug Priority: Major
Reporter: Petter Castro Assignee: Benjamin Eberlei
Resolution: Invalid Votes: 0
Labels: orm, xml

Ubuntu 13.04, Symfony2


When i try to generate my entities mapping in Symfony2 using XML I always get the same error:

Element '


doctrine-mapping': No matching global declaration avail
able for the validation root

I am not adding any column, because first i need to validate the XML which I can't.

<?xml version="1.0" encoding="UTF-8"?>
xsi:schemaLocation='http://doctrine-project.org/schemas/orm/doctrine-mapping http://www.doctrine-project.org/schemas/orm/doctrine-mapping.xsd'>


As you can figure out, my XML is very simple. I am doing just for the validation testing. After this could be validated, I will map my entities.

Thanks for your help.


Comment by Benjamin Eberlei [ 09/May/13 ]

The Doctrine XSD hooks itself into the global namespace, see http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/reference/xml-mapping.html for usage. It should work when you loose the "xmlns:orm" and define the tags as "<doctrine-mapping>"

Generated at Tue Oct 13 19:16:39 EDT 2015 using JIRA 6.4.10#64025-sha1:5b8b74079161cd76a20ab66dda52747ee6701bd6.