Please enable JavaScript to view this site.

Altova XMLSpy 2020 Enterprise Edition

The Results/Messages pane has two tabs:

 

The Results tab shows the data that is retrieved by the query.

The Messages tab shows messages about the query execution.

 

Results tab

The data retrieved by the query is displayed in the form of a grid in the Results tab (screenshot below). When the query results have been generated using the Execute Query command, the XML documents in the Results tab are indicated with the XML icon ic_xmlwithnoedit (screenshot below). If the Execute for Data Editing command was used, XML documents are shown with the Editable XML icon ic_xmlwithedit.

DBQueryResultsOview

The following operations can be carried out in the Results tab, via the context menu that pops up when you right-click in the appropriate location in the Results tab:

 

Sorting on a column: Right-click anywhere in the column on which the records are to be sorted, then select Sorting | Ascending/Descending/Restore Default.

Copying to the clipboard: This consists of two steps: (i) selecting the data range; and (ii) copying the selection. Data can be selected in several ways: (i) by clicking a column header or row number to select the column or row, respectively; (ii) selecting individual cells (use the Shift and/or Ctrl keys to select multiple cells); (iii) right-clicking a cell, and selecting Selection | Row/Column/All. After making the selection, right-click, and select Copy Selected Cells. This copies the selection to the clipboard, from where it can be pasted into another application.

Appending a new row: If the query was executed for editing, right-click anywhere in the Results pane to access the Append row command.

Deleting a row: If the query was executed for editing, right-click anywhere in a row to access the Delete row command.

Editing records: If the query was executed for editing, individual fields can be edited. To commit changes, click the Commit button in the toolbar of the Results tab.

Editing XML records: This feature is supported for IBM DB2, SQLServer, PostgreSQL (8.3 and higher), and Oracle (9 and higher) databases, and only for those DB tables that have a primary key. If the query was executed for editing and an editable field is an XML field, clicking the Editable XML icon ic_xmlwithedit in the Result Grid opens the Edit XML menu (screenshot below). An XML field can also be opened for data editing by right-clicking the XML filed in the Folders pane and selecting the command Edit Data.

DBQueryResWinContextMnu

The Open for Editing command opens the XML document in an XMLSpy window, and the Editable XML icon changes to ic_xmlwitheditopen, in which the three dots are red. When this document is saved and if the Auto-Commit XML Changes icon ic_dbqry_autocommitxmledit in the Query Database toolbar was selected when the document was opened, the changes to the XML document are committed automatically to the database. Otherwise, saved changes will have to be committed using the Commit button of the Results pane. (Note that to toggle between the XML document window and the Database Query window, you must click the DB | Query Database command.) The Load XML Document from File command loads an external XML document to the selected field in the database. The Save XML Document to File saves the XML document in the selected database field to a file location you choose. The Assign XML Schema command pops up the Choose XML Schema dialog, in which you can select an XML Schema to assign to the XML document. This assignment is saved to the database. XML Schema assignment is explained in more detail in the section, IBM DB2 | Assign XML Schema.

Set NULL, Set default, Undo changes for this cell: If the query was executed for editing, right-clicking in a cell provides access to commands that enable you to set a NULL value or, if defined, a column default value for that cell. Changes made to a cell can be undone with the Undo changes for this cell command; the current edited value is replaced by the value currently in the DB.

 

The Results tab has the following toolbar icons:

 

ic_dbqry_gotosql

Go to Statement

Highlights the statement in the SQL Editor that produced the current result.

ic_dbqueryresults_find

Find

Finds text in the Results pane. XML document content is also searched.

ic_dbqry_addnewline

Add New Line

Adds a new row to the Result Grid.

ic_dbqry_deleterow

Delete Row

Deletes the current row in the Result Grid.

ic_dbqry_undoalledits

Undo Changes to Result Grid

Undoes all changes to the Result Grid.

ic_dbqry_commit

Commit

Commits changes made in the Result Grid to the database.

 

Messages tab

The Messages tab provides information on the previously executed SQL statement and reports errors or warning messages.

DBQueryMessagesOview

The toolbar of the Messages tab contains icons that enable you to customize the view, navigate it, and copy messages to the clipboard. The Filter icon enables the display of particular types of messages to be toggled on or off. The Next and Previous icons move the selection down and up the list, respectively. Messages can also be copied with or without their child components to the clipboard, enabling them to be pasted in documents. The Find function enables you to specify a search term and then search up or down the listing for this term. Finally, the Clear icon clears the contents of the  Messages pane.

 

Note:These toolbar icon commands are also available as context menu commands.

 

© 2019 Altova GmbH