Skip to content

What is an XML Namespace?

XML namespaces are used to prevent naming collisions between XML documents and their contents. The namespace provides a way to distinguish between elements that have the same name.

It is easy to imagine an example where there are two separate XML documents; one references a customer element and the other a product element and both elements have a child element named ID_number. If these references were brought together a naming conflict would occur since the elements are identically named, but are not the same. Namespaces provide the solution.

In the Design Studio namespaces are supplied when you create a project. When you enter the name of your project, the namespace field updates to reflect your project names.

New Project Namespace field

Once a project is created you cannot alter the project's namespace. It is important to remember that each namespace must be unique.

To change the namespace prefix for new projects, from the Windows menu, select Preferences, and then choose Project. This is a global setting and will take effect with all new projects.


More information