Dynamic content is what Matik inserts into slides and media and what is mapped to the tags. Dynamic content can be as simple as a static string of text. It can also create powerful insights by taking multiple inputs and querying your data warehouses to create charts and graphs. To put it simply, Dynamic content is responsible for creating each object on a slide.
There are three basic data options for dynamic content:
- Data-Driven: Pulls information from one of your data sources to create the end object.
- Static: Uses preset info to determine the dynamic content. It may also contain input fields from users or images from URLs.
- Conditional: Allows users to determine different dynamic content based on user-defined conditions.
The four output objects of dynamic content are text, charts, tables, and images.
The following shows what output options are available based on each data option.
- Data-Driven: Content connected to data sources, filtered by the inputs selected.
-
- Text: Anything you would insert into a text object within PPT or Google Slides
- Charts: Native charts that are supported within PPT or Google Slides. Matik currently supports bar charts, column charts, line charts, dual axis charts, and pie charts.
- Tables: Native tables in PPT or Google Slides.
- Images: Icons, profile pictures, etc.
-
- Static: Predefined content either in text or image form, typically returning the exact value selected in an input.
-
- Text: Anything you would insert into a text object within PPT or Google Slides.
- Images: Icons, profile pictures, etc.
-
- Conditional: Returns another piece of dynamic content if certain criteria are met.
-
- Sub-Dynamic Content: Inserts another piece of dynamic content if conditions are met.
-
Creating Dynamic Content
To create a new piece of dynamic content, navigate to the Dynamic Content page and Click "+ Add New." You will be presented with options for creating a name, a description, and adding tags. The name of your dynamic content must match the name you will use for tagging in the alt text of slides or media. Note: The name cannot have any spaces and must be unique.
Next, select the data type for your dynamic content.
- Data-Driven: Pulls information from one of your data sources to create the end object.
- Static: Uses preset info to determine the dynamic content. It may also contain input fields from users or images from URLs.
- Conditional: Allows users to determine different dynamic content based on user-defined conditions.
See the relevant sections below for more info.
Data-Driven Dynamic Content
If you have selected Data-Driven, select the data source you would like to use from the list of your data sources.
Once selected, you can select Query or API based on the data source type.
Query
If you select query, then you will need to input SQL syntax to create the dynamic content.
For Query-based dynamic content, it is important to test queries on your preferred query editor in order to optimize for speed. Queries with runtimes over 30 seconds should be examined for ways to improve performance. These strategies could include:
- Aggregating tables to smaller, more performant sizes
- Reviewing order of JOINs to ensure the largest tables are joined first
- Optimizing data transformations and aggregations
Another way to improve performance is to use Sub-Content (see below), which produces several data points to eventually be used in tags instead of one query powering one tag in the template.
API
See the links below for creating dynamic content from API data sources.
Data-source specific dynamic content help articles:
Creating Static Input Dynamic Content
Text Output
When dynamic content is built with a static data source, either text or input can be entered into the text box. If text is entered, that text will appear wherever that dynamic content is tagged in a presentation. If an input is entered into the text box, the user-selected input will be displayed.
In the example below, we create a piece of dynamic content called "Account Name" with an existing input called "account_name" by entering "&:account_name" into the text box. As a result, the account name will be passed through to the end presentation or content when this piece of dynamic content is used.
Image
Upload your image or paste a weblink to create static image dynamic content.
Creating Conditional Dynamic Content
Conditional dynamic content allows you to insert another piece of dynamic content based on input values selected by the end user. For example, let’s say you have “objective” as a parameter, which is a dropdown of five values. You can create conditions that specify which dynamic content is returned based on which values the end user selects. Within a condition group, you will select the input and set the associated criteria for evaluation. Note that you can add multiple conditions within a group, which will be treated as an "AND" statement. If you add another condition group, the dynamic content associated with the first condition group that returns true will be inserted. Matik currently supports the following operators for these conditions: =, !=, > , < , >=, <=, contains, does not contain, in, not in.
Dynamic Content Output Types
Check out this video or keep reading below to learn more about Matik’s supported output types.
Text
If you select text as the dynamic content type, then the data source can be any of the three listed above - Data Connector, or End User Input (Input).
With text dynamic content, the output of your SQL query or API call needs to be a single value. Within the SQL query, you can use inputs to customize the query. End users will be asked to input these, which will customize the query to fetch the appropriate data. See the example query below:
-- SQL query for purchased seats. `&:` represents a Input in the query
SELECT sum(purchased_seats) as total_seats
FROM postgresql.public.qbr_data
WHERE company_name = &:client_name
and contract_id in &:contract_ids
and quarter = &:qbr_date
and time = 'Quarterly'
You can insert inputs within your SQL query by typing &:
. An orange pill will appear above the SQL editor. If this is an input that already exists, the color of the pill will be orange. However, if this is a net new input, the pill will be grey. Click on the pill, and a pane will appear that will allow you to customize the input.
Inserting Hyperlinks and Rich Text Formatting in Text
See our article on Rich Text Formatting for more information.
Hyperlinks can be inserted in Matik Text Dynamic content using a tagging format similar to HTML. Your dynamic content should return text in the following format: <a href="Matik.io">Matik Website</a>
where "Matik.io" is the desired link and "Matik Website" is the link text you want to be displayed in your presentation.
Charts
To make a chart in Matik, add a chart to your Google Slides pr Powerpoint presentation with the data linked to a Google sheet or Powerpoint. When the chart is tagged, Matik will replace the data in the attached spreadsheet with the output of your dynamic content. Therefore, the data structure, columns, and output of your dynamic content must match that of the chart spreadsheet.
You also need to ensure that the chart data in the referenced spreadsheet begins in column a of the sheet and that "Use column A as labels" is selected.
Charts from Queries
If you connect to a database, you need to ensure that the number of columns in the output of your dynamic content matches the number of columns of the Excel/Google sheet that is powering the chart in the slide.
You can make additional edits to the chart after your presentation has been generated by right-clicking the chart and selecting “Open Source.” You’ll be redirected to the underlying Google Sheet that powers your chart. Once you make your changes directly in the Google Sheet, go back to your presentation and press the “Update” button on your chart to sync those changes.
Below is the SQL query that generates the data to fit the schema represented in the Excel spreadsheet above:
-- SQL query for a bar chart
SELECT
quarter as category,
sum(presentations_created) as presentations_created
FROM postgresql.public.qbr_data
WHERE time = 'Quarterly'
and company_name = &:client_name
and contract_id in &:contract_ids
GROUP BY 1
ORDER BY 1 ASC
LIMIT 3
Charts from BI Tools and API connections
You can also power charts with a BI tool or other API connection data sources in which the Fields to Return represent columns in the spreadsheet linked to the native chart.
Tables
Similar to charts, tables are powered by a SQL query or API call to your data source. The output of your SQL query needs to match the table you inserted into the slide. Note that column names in your SQL query need to match the column names you have in your table.
The tables in your template slides cannot contain any merged cells if they are tagged with dynamic content.
Images
Images can be dynamically inserted into slides. You can retrieve an image via the API method or via a URL that is stored in a database. This is retrieved via query.
Sub-Content
You can also create one piece of dynamic content that powers multiple tags within a template. Let’s say you have three metrics that you want to display on a slide, and all three metrics come from the same data source. Instead of creating three different pieces of dynamic content (one for each metric), you could create one piece of dynamic content that outputs all three. For example, let’s say you created a piece of dynamic content called company_seat_stats, and you used the SQL query below:
-- dynamic content name: company_seat_stats
SELECT
company_name,
purchased_seats,
activated_seats,
active_seats
FROM postgresql.public.qbr_data
WHERE company_name = &:client_name
and contract_id in &:contract_ids
and quarter = &:qbr_date
and time = 'Quarterly'
The output of the query above would yield a row that has four columns. When you mark up the template with the tags, you can specify the specific column you want to extract by inputting the following syntax {{dynamic_content_name.column_name}}
. Note that column_name
is case-sensitive.
By adding the “.column_name” you are telling Matik that you only want that piece of data inserted into the tag instead of the entire row.
Only text and image dynamic content is supported in sub-content. The type (text or image) must be consistent across all sub-content and appropriate option selected. Charts, and tables are not compatible. The output of your query can not return multiple rows.
Bulk Actions
Bulk Actions allow you to make multiple changes to dynamic content, permissions, data sources, and tags in one go, instead of updating each piece of content individually.
To apply bulk actions to dynamic content, navigate to the “Dynamic Content” tab, select the pieces of content you wish to update, and then select your bulk action. You can select “Manage Access,” “Manage Tags,” or “Update Data Source.”
To apply bulk actions to permissions, select “Manage Access.” You can share the content with new users or adjust viewing and editing permissions for existing shared users. When you’ve finished making your changes, press “Close.”
To apply bulk actions to tags, select “Manage Tags.” Add or remove tags to re-categorize and organize your content. Then, press “Save” to save your changes.
To apply bulk actions to data source updates, select “Update Data Source.” Search for the data source you would like the piece of content to pull from, select it, and press “Save.” Note that this option will only be available if you select pieces of content tied to the same data source.
Comments
0 comments
Please sign in to leave a comment.