An XQuery or XQuery Update document is opened automatically in XQuery editing mode of Text View if it is XQuery or XQuery Update conformant. A file is defined as conforming to a certain document type in the File Types section of the Options dialog (Tools | Options | FileType, screenshot below).
File extensions currently defined as XQuery and XQuery Update in XMLSpy
.xq .xql .xqr .xquery
Setting additional file extensions to be XQuery conformant
To set additional file extensions to be XQuery conformant:
1.Select Tools | Options. The Options dialog appears (screenshot below).
2.Select the File Types section.
3.Click Add new file extension to add the new file extension to the list of file types.
4.Under Conformance, select XQuery conformant., and then XQuery or XQuery Update.
You should also make the following settings:
•Description: XML Query Language or XQuery Update Facility
•Content type: text/xml
•If you wish to use XMLSpy as the default editor for XQuery files, activate the Use XMLSpy as default editor check box.