xsd

convert database table into XML schema file

Hello everyone, I am using SQL Server 2005. Is there any command or GUI tool (e.g. any menu/function from SQL Server management studio) to convert database table into XML schema file (.xsd)? thanks in advance, George ...

Getting parameters for web service programmatically?

Hi. I have a web based system where users should be able to fetch data from a web service by entering the URL and the necessary parameter values. My problem is, somehow I need to find out the structure of the parameters required in the soap body, which is not necessarily just one or two strings, but could be a whole object tree. Trans...

Generating XSD schemas for .NET classes

I have a set of classes which hold only data (no operations have been defined in this class). How do i generate a xsd file for these classes? ...

xsd attribute and element validation

I am trying to create an XSD schema which will validate the following xml. <Item ItemGUID="3F2504E0-4F89-11D3-9A0C-0305E82C3301">The name of the item</Item> I want to validate the max length of the attribute "ItemGUID" to 36 characters and "The name of the item" to a max 25 characters. How can it be validated to satisfy the above con...

Less Cumbersome Way To Document XSDs?

We recently started providing a data extract to clients via an XML. We have a schema (XSD) that defines the structure of this XML. I would like to include the documentation of the elements and attributes in the schema itself. The only thing I am finding is the very cumbersome "annotation" and "documentation" tags. So you take somethi...

XSD complains with "Multiple elements with name 'B', with different types, appear in the model group."

I have the following XSD: <xs:complexType name="typeBroken"> <xs:choice> <xs:element name="B"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:pattern value="FOO|BAR" /> </xs:restriction> </xs:simpleType> </xs:element> <xs:sequence> <xs:element name="A"> <xs:simpleT...

How do you resolve a URN?

I have an XML schema file which references a urn based location. Is there some way to resolve this into a url, or some way to actually read the file it refers to. <xs:include schemaLocation="urn:oasis:names:tc:dita:xsd:tblDeclGrp.xsd:1.1"/> ...

Middle way between XSD all and XSD sequence

I'm defining a user element with XSD. For this example, a user has a name, email and one or more nationalities. I've tried: <xs:all> <xs:element name="name" blabla /> <xs:element name="email" blabla /> <xs:element name="nationality" minOccurs="1" maxOccurs="unbounded" /> </xs:all> However, that is illegal. Apparently elements in...

BizTalk generated XSD fails to validate the XML its derived from

I've got an XML response from another system, but no XSD, so I used the Create Schema option to generate one. I then added the XSD to my BizTalk 2006 R2 project and set its "Input Instance Filename" property to the original XML message. Tried the "Validate Instance" option and it FAILS ???, with a couple of errors like so ... error BEC...

How to validate a pick list with an XML Schema

Hi I've got this problem and I can't for the life of me find a simple solution. I am trying to codify a list of operating systems, where the XML file contains a list of the OSes that a given person has. There is a fixed list of OSes (XP, Vista, Win7, OSX and Ubuntu). I have the following piece of XML <operatingSystems> <operatin...

Generate XSD from 2005 SQL Server Database

What is the easiest method to generate an XSD schema from a 2005 SQL Server Database? Would it be possible to generate one XSD schema for the entire Database (~100 tables)? I searched online and found a SQL example that generates one XSD for the one table: DECLARE @schema xml SET @schema = (SELECT * FROM MyTableName FOR XML AUTO, ELEM...

Same element, multiple types with XML Schema

I want to construct the following XML: <?xml version="1.0"?> <foo> <bar type="alpha"> <first /> <second /> </bar> <bar type="bravo"> <third /> <fourth /> </bar> </foo> The salient point being that I want "bar" to have different child elements depending on its type -- if the type is "alpha" then the children MUS...

xsd for wsdl in coldfusion

How to generate an xsd from the wsdl generated in Coldusion? I'm no sure how the xsd is useful for creating SOAP stub but someone needs it so need to find a way to generate one. I tried using some online tools for this but it says "inline definitions". Hopefully some one knows how to do this. ...

How to get case-insensitive elements in XML

Hi! As far as I know XML element type names as well as attribute names are case sensitive. Is there a way or any trick to get case insensitive elements? Clarification: A grammar has been defined via XSD which is used for some clients to upload data. The users -the content generators- are creating XML files using different tools but ma...

In .NET, does the entire XML blob come into memory when I validate against a XSD?

If I have a large (>500MB) XML file to validate, does an XmlReader bring the whole thing into memory to perform validation? I looked at http://stackoverflow.com/questions/751511/validating-an-xml-against-referenced-xsd-in-c for validation procedure. thanks, Mark ...

Generating a Xml document from a simple XSD schema

I have a xsd file and I need to generate a xml file from it. What is the easiest way to achieve this? EDIT: There is a similar question here and so i want to close my question. However if you have an answer please post it... EDIT: One of the respondents deleted their answer, but i found it to be the simplest solution that works for me....

Usage of XSD occurrence Indicators

XML Schema specifies "occurrence indicators" (maxOccurrence, minOccurrence). Is there a "best pratice" in which elements (xsd:element, xsd:sequence or xsd:all) these indicators should be used? Example: either <xsd:element name="XList"> <xsd:complexType> <xsd:sequence> <xsd:element name="X" type="xsd:token" minOccurs="...

Can I use xsd:complexContent with the Delphi XML Binding Wizard?

The Delphi 2009 XML Data Binding Wizard fails to process a simple XSD which contains a complexContent declaration (Invalid Pointer Operation). Is it a bug or a know limitation? Example: <?xml version="1.0" encoding="utf-8"?> <xsd:schema targetNamespace="http://example.org/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" elementF...

Get List of all non-builtin Types from WSDL?

Given a WSDL/XSD, what's the easiest way to produce a list of all simple & complex Types? (Java preferred.) i.e. <xsd:element name="ThirdPartyProductInfo" type="typens:ThirdPartyProductInfo" minOccurs="0"/> <xsd:element name="SalesRank" type="xsd:string" minOccurs="0"/> <xsd:element name="BrowseList" type="typens:BrowseNodeArray" minOc...

Convert xml to xsd using java

I am looking for a tool or java code or class library/API that can generate XSD from XML files. (Something like the xsd.exe utility in the .NET Framework sdk) ...