Information Classification: External Restricted.


Working with DataSources within CHILI Editor allows end users to select or upload databases for use with Variable Data.

To get started, an administrator needs to set up the definition for a DataSource in CHILI BackOffice (in the External Systems>DataSources menu). 
These can be selected within the editor (potentially only by an administrator), and used to create PDF output (configured in PDF Export Settings).

DataSource Settings

DataSources are configured by administrators in CHILI BackOffice.

Each datasource has a type, determining how data will be selected by the end user. This can be:

  • File Upload

  • Google spreadsheets

  • External URL

  • Salesforce

Regardless of the type, a list of columns can be defined in the DataSource settings. For file uploads, these can be used to perform basic validation of the uploaded files (checking for required columns). 
Otherwise the column definitions control the visualization of the data in CHILI Editor (columns can be made visible, get a different header text, ...). Columns do not require to be defined here. 
If the "append all columns" checkbox is checked, all fields will be shown in CHILI Editor. And populating variable data is done regardless of column definitions (based on the variable names).


File Upload

For DataSources of this type, the user has the possibility to upload a data file within CHILI Editor. Supported file types are:

Textfiles are supported with these encodings

Google Spreadsheets

This type allows you to make a connection with your Google Docs account and use your online spreadsheets in the editor, as datasource.

As of version 4.5 the setup for google spreadsheets has changed due to changes on the Google API side. (read about it here)
You now need to provide a Client ID, Client secret and an Access Code (can be generated when the first two are supplied). 
The procedure to obtain those is described here: Obsolete - Google spreadsheet setup


Similar to Google Spreadsheets. This allows you to use the information you have on your salesforce account in to your documents in CHILI Publisher

External URL

A DataSource of this type allows users to select parts of external databases. An external system can set up dynamic web pages returning XML describing the data.
See the API Guide for a description of the XML formats.

DataSource Panel in Editor

Within CHILI Editor, a datasource can be used in the DataSource panel. This is included in the default workspace in the right "Variables" tab, above the variable data itself.
The panel allows administrators to set up properties to prevent certain actions for end users (eg: selecting the datasource).

 After uploading a file or selecting a query, the user gets a grid of the available data. Upon changing the selection in that grid, variables within the document are populated (based on the name of the column in the data).
Variables can be created based on the columns found in a datasource.

You can filter on a specific value, but also to show the longest or shortest value for a field in a datasource. This function can be shown or hidden from the end-user.
Via the "Use filtered results for PDF generation"  a PDF can be generated base upon the filtered results. This is only valid for the time of the session. Filtered results are not saved with the document.


DataSource Panel in Editor

Values from a "document variable" can be pushed back to the imported datasource file and saved in the CHILI Publisher document.
A checkbox in the settings of the variable takes care of this.

PDF Export Settings

Once the user has walked through the data, you may offer him the possibility to create a merged PDF file. You can set this in the  "DataSource" tab in the PDF Export Settings.

Next to some general settings on amount of rows to be created (for example for a preview of the data containing only 10 records), these settings also work with two types of content:

  • variable data

  • background

The content can be configured in CHILI Editor in the "Layer Settings" panel. Each layer can be either of these types, or "Unspecified" (in which case the default content type is configured in the PDF Export Settings).
Based on this content, a background PDF can be created, or the background can be omitted from the variable data PDF files.

As of version three, you can specify the engine that will be used to create the pdf:

  • Legacy server rendering (Flash) - (used to be "Editor CLI" but the label changed since

  • HTML server rendering - (Used to be "Server rendering [v3.0+]")

The server rendering will be used when the generation of the pdf is initiated in the editor. The server rendering allows you to generate the pdf files without having to open them first in the editor. You specify the file and the data. The merge of both will be taken care of by the server with a pdf as end result.


Datasource format in XML

Since version, the structure of the datasource has changed in our object model. Older versions stored the content of the datasource as a serialized text in an attribute called xmlstring.

Since, the content is placed as valid XML in the content node of the datasource node.

<document> ... <dataSource dataSourceID="c57038dd-182c-451b-b6c8-035c5a1f83bd" fileName="simple datasource.txt" hasContent="true" lastLoadedQueryString="doc=1674528f-cdd2-437d-be96-102022aa3d11&amp;apiKey=xyl678LaRqKrOK0VNtB9HueCj9P6JwOEBceqZF9bvIk+Jh0R4VCCxTzta5VO7nagxHx9H58K9Cr4FeOndtv8VQ==&amp;enable3D=true" numRows="3" selectedFile="" selectedQuery="" selectedSpreadsheet="" xmlString=""> <content> <dataSource> <row rowNum="1"> <col1 varName="ID">1</col1> <col2 varName="color">red</col2> <col3 varName="name">Jean</col3> <col4 varName="value1">a</col4> <col5 varName="value2">k</col5> </row> <row rowNum="2"> <col1 varName="ID">2</col1> <col2 varName="color">green</col2> <col3 varName="name">Jacques</col3> <col4 varName="value1">b</col4> <col5 varName="value2">l</col5> </row> <row rowNum="3"> <col1 varName="ID">3</col1> <col2 varName="color">blue</col2> <col3 varName="name">Jeanne</col3> <col4 varName="value1">c</col4> <col5 varName="value2">m</col5> </row> </datasource> </content> </datasource> ... </document>

This change made the processing of variable data a lot more performant. 
It also opens possibilities to interact with these datasources in an integration. You can inject datasource content in the document XML and build performant variable data applications.

All information on this page must be treated as External Restricted, or more strict.