Welcome to MSDN Blogs Sign in | Join | Help

Browse by Tags

All Tags » XSD   (RSS)

Silent XQuery failures

A newsgroup post I read earlier today reminded me that there are cases where failure to get the expected result when using XQuery can sometimes be difficult to diagnose. Here’s what the poster was doing declare @xml xml set @xml = '<root><test></test></root>'

Mixed content (part 3)

It’s been a few weeks since my last post about mixed content so let’s pick up right where we left off. This time we will look at DML operations on mixed content. We’ll keep using the XML schema as well as the table I created in the first post of this
Posted by denisruc | 1 Comments
Filed under: , ,

Mixed content (part 2)

Following last week's introduction to the concept of mixed content, let's look in detail at a validated XML instance with mixed content. Taking a look at the children nodes of the <letter> element Let’s reuse the instance we stored in our table
Posted by denisruc | 1 Comments
Filed under:

Mixed content (part 1 of many)

I started working on this two days ago. I quickly realized that when I’m done I’ll most likely have material for multiple posts. My original plan was to finish the article in the next few days, and then publish it as several posts over time. However I
Posted by denisruc | 4 Comments
Filed under:

xsi:nil magic (part 2/2)

Last time we looked at what happens to the xsi:nil attributes when replacing the value of a simply typed element. In this post, we’re going to look at complex types. First let’s create a schema collection with complex types and elements. CREATE XML SCHEMA
Posted by denisruc | 0 Comments
Filed under: ,

xsi:nil magic (part 1/2)

A few months ago I wrote a post about the interesting behavior of the xsi:type attribute . Today we’re going to look at his no so distant relative xsi:nil. But first let’s do a quick recap. Any element can be made nillable by adding the attribute nillable=”true”
Posted by denisruc | 1 Comments
Filed under: ,

Complementing XSD with CHECK constraints

I was recently asked to look at a customer’s question. This person wanted to write a schema that would validate instances like the following one. <TopElement> <a> <element1 att1="data1" att2="data2"/> <an_element att1="data 1" att2="data
Posted by denisruc | 3 Comments
Filed under: ,

xsi:type magic

As I said in my previous post, the past few weeks have been demanding and I had little time to spend on blog post. However I recently rediscovered an interesting behavior in typed XML DML and I felt I should make some time for a quick post. Today’s post
Posted by denisruc | 3 Comments
Filed under: ,

Explaining the reasons behind some of XML datatype's limitations

If you use XML in SQL Server 2005, and especially if you use it in association with schemas, I suggest you read Brandon's recent blog post about the limitations that were placed on the XML datatype. Brandon is one of our developers and he's got first-hand

Importing the Microsoft Office 2003 schemas into the database

As promised earlier I'm going to give you an example using a real-world schema. I've chosen to work with the Office 2003 schemas but I'm going to limit myself to Word and Excel. First, you need to install the schemas from here . In the T-SQL samples below
Posted by denisruc | 1 Comments
Filed under: ,

Download SP1 today!

Yesterday we released our first Service Pack for SQL Server 2005 . You might remember a while back I had written a small post about being hard at work on SP1. Back then I avoided giving any details for fear of running afoul of corporate policy but since

Importing an existing XML schema into SQL Server 2005

In my last post I addressed the issue of non deterministic content models, which can be valid with respect to the W3C’s standards, but which are always rejected by SQL Server 2005. There are a few other XSD features that SQL Server 2005 doesn’t support.
Posted by denisruc | 13 Comments
Filed under: ,

Fixing non deterministic schemas

If you’ve been importing XML schemas into SQL Server 2005 you might have encountered this error message XML Validation: XML instances of the content model of type or model group '…' can be validated in multiple ways and are not supported. The reason for
Posted by denisruc | 1 Comments
Filed under: ,

How to preserve whitespaces

For once I'm going to venture outside of the realm of typed XML and address an issue that might be of concern to users of untyped XML as well. We've been asked a few times if we had a solution to preserve non-significant whitespaces in an XML instance.
Posted by denisruc | 1 Comments
Filed under: ,

Using the XPath provided in XML validation error messages

Yesterday’s post regarding the addition of a location in validation error messages brought back a conversation I’d had with our Program Manager regarding the use of that XPath to automatically retrieve invalid XML fragments when validation fails I’ve
Posted by denisruc | 0 Comments
Filed under: ,
More Posts Next page »
 
Page view tracker