Hi,
I was wondering can I ORDER BY my query by node of an XML typed column?
For example I have a table
ID (int) | Data (XML)
Where Data column stores XML in form similar to this
<?xml?>
<Data>
<SimpleOrderedValue>1</SimpleOrderedValue>
<ComplicatedInternals>
...
</ComplicatedInternals>
</Data>
I want query this table ordered by SimpleOrderedValue. Can I do this on MS SQL Server 2008 with XML column? Or can I do thins using CLR UDT, but without additional computed column and in a way so that Data column were indexed (for faster search).
Will appreciate any help. Thanks.