Add a table to an existing Views element
- Last UpdatedApr 24, 2025
- 1 minute read
Follow the procedure below to add tables to an existing Views element.
To add a table to an existing Views element
-
Navigate to the %DNADataRoot%\ADE\config\ADE\TreeLayout\Schema\custom\<component> directory.
-
Create or open the DNATreeLayoutSchema.Alter.xml file.
-
Add the Tables element to the file within the Views element:
Note: In our example, the view type is called farms.
<?xml version="1.0" encoding="UTF-8"?>
<DNATreeLayoutSchema xmlns="http://www.telvent.com/DNATreeLayoutSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.telvent.com/DNATreeLayoutSchema
..\..\..\DNATreeLayoutSchemaAlter.xsd">
<Views ViewType="Farms"
<Tables
Type="Table"
Label="Farms"
TableName="farms"
PrimaryKeyField="name"
DescriptionField="description"
UseDistinct="false"
CanOpenTable="true"
CanOpenRecord="true"
FromClause="FROM "farms""
WhereClause=""/>
</Views>
</DNATreeLayoutSchema>
For information on the Tables attributes used in the file, see Tables element attributes.
-
Save and close the file.
-
On the desktop, double-click the Windows PowerShell for DNA shortcut.
Windows PowerShell for DNA opens.
-
Execute the DNATreeLayoutSchemaMerge command (see Merge all DNATreeLayout XML files).