Page tree
Skip to end of metadata
Go to start of metadata

The design of a Data Source specifies the selection of tables in the data source, any derived tables, joins, calculated fields, and filters, as well as how those elements appear to users. In Zoola™, the Data Source design can be created interactively through the Data Source Designer, however there is also an XML file format for exporting and uploading the settings. The text file containing a Data Source design represented in XML is called a design file.

The XML in a design file is a hierarchy of elements and attributes on those elements that specifies all the settings in the Data Source. The elements and attributes are defined by an XML schema provided in an XSD file . In addition, there are constraints on a Data Source design that are not expressed in the XML schema. A design file can be modified or written from scratch in an editor and uploaded to the server, as long as it conforms to the XML schema and the design constraints.
XML is not the native format of the Data Source design. The XML file is only a representation from which the design can be inferred. A design has additional constraints that are not mapped in the XML format. 

There are several common use cases for working with design files: 

  • Completing the elements of a new design. Use the Data Source Designer to define as much of the design as possible, then export the design file and add your handwritten code to the exported file. For example, you can enter the SQL query for a derived table or complex expressions for a calculated field. 

  • Working with very large Data Sources. The Data Source Designer makes it easy to select all tables and columns and expose them as sets and items, but editing the labels and descriptions of dozens of items is faster when they appear in a single design file.

  • Making repetitive changes to an existing Data Source design. If the database changes or you want to move a design file to a different system, you may need to edit each table or item in the design in the same way. Using search-and-replace on an external editor does this quickly. 

  • Creating a Data Source design from scratch. It is possible to write a valid XML file that meets the constraints of Zoola™ and defines a Data Source design. However, due to the complexity of creating a valid design file, it is much easier to begin with a basic design file exported from the Data Source Designer or to modify an existing design file. 

After editing, a design file can be uploaded, validated, and used to define the design of a new or existing Data Source. When you open the design in the Data Source Designer again, the modifications appear and are editable in the Designer. For example, a description you added in the XML design file appears in the Properties table of the Display Tab, and you are be able to edit it again the Designer. Other elements of the XML file appear on some or all of the Designer tabs. 

  • No labels