XSD, a quick introduction
I often get asked to explain how XSD:s work and everytime I explain it in a different manner. I thought that if I document one way here I could later reference it for the rest of my life 🙂 I
Just another Tech blog from a forgetful mind
I often get asked to explain how XSD:s work and everytime I explain it in a different manner. I thought that if I document one way here I could later reference it for the rest of my life 🙂 I
Sometimes you just want to validate any number of elements any number of times. There is no intuitive way in XSD to accomplish this so we have to use a trick to get it to work. The solution looks a
The xml namespace is the default namespace but sometimes you need to define it when working with xsd. The secret here is that the xml namespace only accepts one particular uri (“http://www.w3.org/XML/1998/namespace”). Here is an example of an xsd validation
This took some time to figure out. They do not make it easy for us 🙂 I am here going to show the basics of validating an XML with multiple namespaces. In the example I will use two namespaces. XML
Say you have an element looking like this: Catcher in the rye and that element is allowed to also be empty. Like this: <book/> How do you validate it? One way is to use the attribute “nillable” like this <xs:element