XML Nodes Versus XML Attributes

Decided to speak about this as found that many developers are misusing XML nodes and XML attributes.

In my opinion node should be used only in case if it can have attributes. In this case XML

[Authors] [Author] [Name]Paulo[/Name] [SurName]Coelho[/SurName] [/Author] [/Authors]

Should be redesigned into XML

[Authors] [Author Name="Paulo" SurName="Coelho"/] [/Authors]

I faced [...]

XSLT and XPath selecting distinct nodes

It is a complicated task to select distinct nodes or to use grouping useing xslt. There are no simple syntax to write this type XPath query.

The work arround is quite difficult to remember, thats why i decided to duplicate internet content in my blog.

Let’s say, that the XML source is:

<root> <MyData [...]