Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Qlik Sense documentation and resources.
{
"appId": "58f563b6-ccda-45b0-926c-e2992ca8b470",
"recurrence": [
"RRULE:FREQ=MINUTELY;INTERVAL=15"
],
"startDateTime": "2022-03-23T00:00:00",
"timeZone": "America/New_York",
"type": "scheduled_reload"
}
This guide was written for use with the Windows PowerShell program. While PowerShell can be run on non Windows systems, use of bash techniques for parsing json (e.g. jq) is possible but not covered in this guide.
Reload a specific app every 15 minutes
# Specify the appId
$appId = '<myAppId>'
# Define the rrule
$schema = 'RRULE:FREQ=MINUTELY;INTERVAL=15'
$startDate = ((Get-Date)).ToString("yyyy-MM-ddT00:00:00") # Get the current date and convert to required format
# Get the app's reload tasks
$reloadTask = qlik reload-task ls --appId $($appId) | ConvertFrom-Json
# Delete the associated reload task, if present
if($reloadTask.data.Length -gt 0) {
$null = qlik reload-task rm $($reloadTask.data.id)
}
# Create the task
$null = qlik reload-task create --appId $appId --recurrence $schema --startDateTime $startDate --timeZone "America/New_York" --type "scheduled_reload"
Reload a specific app every hour on Thursday
# Specify the appId
$appId = '<myAppId>'
# Define the rrule
$schema = 'RRULE:FREQ=HOURLY;INTERVAL=1;BYDAY=TH'
$startDate = ((Get-Date)).ToString("yyyy-MM-ddT00:00:00") # Get the current date and convert to required format
# Get the app's reload tasks
$reloadTask = qlik reload-task ls --appId $($appId) | ConvertFrom-Json
# Delete the associated reload task, if present
if($reloadTask.data.Length -gt 0) {
$null = qlik reload-task rm $($reloadTask.data.id)
}
# Create the task
$null = qlik reload-task create --appId $appId --recurrence $schema --startDateTime $startDate --timeZone "America/New_York" --type "scheduled_reload"
Reload a specific app on the 2nd Monday of the month
# Specify the appId
$appId = '<myAppId>'
# Define the rrule
$schema = 'RRULE:FREQ=MONTHLY;WKST=MO;BYDAY=MO;BYSETPOS=2'
$startDate = ((Get-Date)).ToString("yyyy-MM-ddT00:00:00") # Get the current date and convert to required format
# Get the app's reload tasks
$reloadTask = qlik reload-task ls --appId $($appId) | ConvertFrom-Json
# Delete the associated reload task, if present
if($reloadTask.data.Length -gt 0) {
$null = qlik reload-task rm $($reloadTask.data.id)
}
# Create the task
$null = qlik reload-task create --appId $appId --recurrence $schema --startDateTime $startDate --timeZone "America/New_York" --type "scheduled_reload"
During a workshop, the most tedious part is to assign a QlikCloud user into the workshop space. With Qlik Application Automation , this process can be automated from the creation of the space to the assignment of the user into the specific space.
First, I created a google sheet that contains the list of users email, and 1 sheet correspond to 1 workshop.
I used the List Sheets Of Spreadsheet block to list out all the sheets within this workbook
Then I used the Condition block to check whether the sheet is prefix with *. This provide a mechanism to skip any sheet by renaming the sheet.
If it is not prefix with *, the Create Space block will create a space for each sheet using the name of the sheet. You will need to set the type of share and most importantly, set on error to ignore and continue automation and ignore errors. This will ignore this block when the space has already been created.
Once the space is created, the Search Spaces block is used to retrieve the ID of the space as the space assignment is by the ID
Next, the Get Data From Sheet With Headers block is used to retrieve the list of users email from the google sheet
For each user email, the Search Users block is used to retrieve the ID based on the email address.
With both the Space ID and User ID, the Add Member To Space block is used to assign the user into the space. Note the type of roles to assign to the user and the type of member. Also set the on error to ignore and continue automation and ignore errors in case the user has not signed up yet. This will ignore this user and move to the next user.
The following is the entire flow of the Qlik Application Automation
This can then be scheduled to run everyday and possibly more frequently just before the start of the workshop.
Task chaining is not yet available in the user interface of Qlik Sense Enterprise SaaS, but it is possible to accomplish through the API's.
One such example is the Task Chaining with qlik-cli found at qlik.dev, that example does however require the user to handle the scheduling themselves and also somewhere to execute the API calls .
The attached document will instead showcase an example of how to configure task chaining without an additional server and utilize the schedules defined in Qlik SaaS. It will be running in AWS Lambda and rely on one of the webhooks available in Qlik SaaS in combination with the Qlik RESTful Reloads API.
Schedule/reload any app in a chain through the SaaS Hub and rest of the chain will execute as defined.
Have you ever noticed, when you have the same app open twice and make selections, those selections are reflected in all your open tabs? This is because they are all open using the same session/identity.
This has been one of the most requested features by our users as they like to compare things side by side, without changing the selections every time, or having to build charts with alternate states.
Luckily, there is a way to bypass this using the Qlik Single integration API.
The Single Integration API provides parameters that can be used to create an URL that returns a complete HTML page containing for example an embedded Qlik Sense visualization. This URL can be embedded in a web page, for example by including it in an iframe.
Here's how :
Voilà! You are now able to make different selections for the same app!
If you are reading this and perhaps don't even know what a Dynamic View is, don't worry, you are in good company. It's been perhaps one of Qlik's best keep secrets.
Not sure why so many have kept it a secret but you know I'm an open book. I want you, or specifically your end users, to have access to all of the goodies and Dynamic Views is certainly one of those.
If you do know what Dynamic Views are then stay here and watch the video to see that Dynamic Views are still very much supported in Qlik Sense Enterprise SaaS. In fact, if anything you may see that the code to implement has gotten even easier. Then feel free to read the blog I wrote for DataOnThe.Rocks.
If you are not familiar with Dynamic Views then read the blog first. That way before you start thinking about implementation you understand WHAT Dynamic Views are and WHY I think so highly of them and what they offer your end users. Once you understand the concept and the consumption then the video is your next step.
In my previous blog I have shared how to assign users into spaces. Now I have a request to unassign them from the spaces so that all the apps that they have created will be frozen, i.e., they will not be able to make further changes. This is good for hackathon where they can make use of the assigned space to build their submission and once the deadline for submission is over, they will not be able to make any more changes. With Qlik Application Automation, this process can be automated from by downgrading the user's role to read only.
First I will loop through all the spaces using the List Spaces block
I used the Condition block to check the name of the spaces if it fits a predefined pattern
In my scenario I have suffix all the spaces with DAT2022, so the condition will be if the first 7 characters contain 'DAT2022'
I will then list down all the members within the space using the List Members from Space block
Next I will update the roles of the user using the Update Roles of Member from Space
I will need to specify the space ID, User ID and the Roles. In this case I will set them as 'consumer' which has view only rights
The following is the entire flow of the Qlik Application Automation
When there is a change in owner for an app, we can go into the management console to change. However if we need to change all the app for multiple owners to another, it will be tedious to do it one by one. One solution is to use Qlik Application Automation to automate the change
First, I created a google sheet that contains the pair of the change: list of old email and new email.
I used the Get Data from Sheet block to read the old email and new email
Next I used the Search Users block to retrieve the user ID based on the email for both the old and new email
Then I list out all the apps using the List Items block with ResourceType = app
Then I use the condition block to check if app Owner ID matches the user ID of the old email
If it matches then update the owner using the Update App Owner block
Set the Owner ID based on the output of the Search User block to the application whose App ID based on the output of the List Items block
The following is the entire flow of the Qlik Application Automation
Version 1.7 - A new feature for the front end!
With the latest version, you can now quickly copy the output in expression editor windows using a button.
Check it out on YouTube : https://www.youtube.com/watch?v=CXPMbQSD9mQ
It is very likely that many of you build your data models so that you can easily reuse certain parts, such as dimensions.
Although some development methods such as the Qlik Deployment Framework (QDF) help speed things up, the task of renaming fields when reusing a QVD is still time-consuming.
Let's imagine that a fact table contains 3 customer dimensions and 2 warehouse dimensions and that for each of these dimensions you add a prefix, or that your fields are written in a multilingual way ([Customer/Customer/Cliente]) and you want to get the middle value. You could also use it to rename fields from an SQL database and format everything for a nice front-end result in Qlik.
It's now easier than ever with Sense Field Formatter.
(https://youtu.be/k3HQpJivyZM)
Allows a user to format a list of fields, delimited by commas, into an alias and standardized format.
The user has multiple configuration options to choose from.
When the extension icon is clicked, a popup menu is displayed where the formatting takes place and is pasted into the clipboard.
Will use the alias name (at the right of "AS") from your source fields as your new source fields.
e.g. [SourceField] AS [SourceAlias] -> [SourceAlias] AS [OutputAlias]
The character(s) used to identify the key fields in Qlik. Formatting will be handled differently here as the Prefixing will be done AFTER (the right) the key prefix to avoid breaking the key formatting.
e.g. Prefixing a key field with "Customer." will generate this: [%MyKeyField] AS [%Customer.MyKeyField]
Ignore formatting on Key Fields?
Fields starting with the identified key will NOT be formatted.
Places the comma either at the start or end of the line.
Should the field delimiters be double quotes or square brackets.
Find what: The character(s) you are looking to replace. Multiple characters can be replaced at once.
Replace with: Replace all occurrences of the character(s) in the fields.
Will insert a space before each capital letter in the fields, except for the first character.
e.g. [MyNewField] -> [My New Field]
Applies a case change to all the fields.
Uppercase: Replaces each lowercase letter with a corresponding uppercase char.
Lowercase: Replaces each uppercase letter with a corresponding lowercase char.
Capitalize: The first letter of each word will be in uppercase.
Extract substring components from a parent string field, where the original record fields consist of two or more parts separated by a delimiter.
The function can be used, for example, to extract the column name in a specific language if the field is multilingual.
*e.g. Applying a subfield of 3 with a delimiter of '/' [Client/Cliente/Customer] -> [Customer]
Delimiter: A character within the input text that divides the string into component parts.
Field no: Specifies which of the substrings of the parent string text is to be returned. Use the value 1 to return the first substring, 2 to return the second substring, and so on.
Adds an affix, either placed before the field (prefix) or at the end (suffix). Useful when reusing the same dimension over and over for multiple scenarios.
e.g. Using the customer dimension where a customer may be a Ship To or Bill To customer.
Prefix : [Customer Name] -> [ShipTo.Customer Name]
Suffix : [Customer Name] -> [Customer Name.ShipTo]
Affix: The text that will be used as an affix. Make sure to add a space to your affix if you'd like the new string to remain spaced out.
Installing the plugin
Visit the Store:
Visit my GitHub: https://github.com/MichelLalancette/SenseFieldFormatter
Qlik Analyzer Capacity licences are a great way of allowing a large number of infrequent users into your Qlik apps. Out of the box though it is not easy to monitor their usage in Qlik Cloud (SaaS).
This app uses the licences API to find how many minutes of capacity there are on the server, how many minutes have been consumed and where you would expect usage to be on this day of the month, given a calculated run rate. If usage is higher than a set threshold then an email is sent notifying of this.
The app is designed to work in Qlik Cloud, but can be modified to work in Qlik Sense Enterprise for Windows (client managed) also.
There is a blog post accompanying this app, with full details of how it is put together and how to configure it. You can find this here:
https://www.quickintelligence.co.uk/sense-capacity-licence-notify/
The app is not much to look at, but the email in your inbox could save you from having users locked out:
If you have any questions or comments on the app, please add them to the comments below, or on the blog post itself.
If you like this app then you may find some of our other apps useful, find these here:
https://www.quickintelligence.co.uk/examples/
All the best,
Steve
https://www.quickintelligence.co.uk/blog/
Qalyptus Cloud completes Qlik Sense SaaS with reporting capabilities. It offers the possibility to design custom reports and distribute them in different standard formats to unlimited recipients.
This article will introduce Qalyptus Cloud and how to move to Qlik Sense SaaS when you have NPrinting.
Qalyptus Cloud is a multi-tenancy solution hosted by Qalyptus and compatible with Qlik Sense Business and Enterprise. Your Qalyptus tenant has its database and files storage shared space. No installation is required or infrastructure to manage.
Qalyptus Cloud allows you to design reports using your preferred tools. Get the power of Excel, Word, PowerPoint, and HTML to create pixel-perfect reports and answer your users’ questions.
Use your native or third-party (extensions) Qlik Sense visualizations in the report as an image or data table. Qalyptus will generate the report by receiving the image placeholder size and the table design. You are in control.
Use your SMTP server to distribute reports to an unlimited number of users. Send the same report to all recipients or a filtered one for each recipient to see only the data to with he is entitled.
Qalyptus Cloud has a very detailed permission management system. Different roles exist to define user rights.
You can decide which permissions you want to give to each user for each element (task, report, filter, etc.).
When you have NPrinting with Qlik Sense for Windows and want to move to Qlik Sense SaaS, you need to migrate your Qlik Sense for Windows to the Qlik Cloud platform and use an alternative to NPrinting because NPrinting is not compatible with Qlik Sense Cloud.
Migrating to Qlik Sense SaaS is not plug-and-play as many things are not handled the same way, including data connection, security management, and authentication mechanisms.
We recommend you follow the instructions described in the Migrate to Qlik Cloud section in the Qlik Help.
To understand the main differences between the two Qlik Sense SaaS editions (Business and Enterprise), we recommend you to read our article: Qlik Sense Business or Qlik Sense Enterprise? Which one is most suitable for you?
Using Qalyptus with Qlik Sense SaaS when you already have NPrinting allows you to reproduce almost all of your reports. In addition to integrating nearly all the features of NPrinting, Qalyptus offers more advanced reporting possibilities and unequaled ease of use.
The good news is that you can reuse your existing NPrinting report template files (Excel, Word, PowerPoint, and HTML). All you need to do is replace the NPrinting shortcodes and image placeholders with the Qalyptus ones.
You can export your recipients from NPrinting and import them from an Excel file. If you defined filters for users, forget them. In Qalyptus, it is very easy to filter reports per user. You don't need a complex configuration to send a filtered report to users. In Qalyptus, the process is very simple and doesn't need any configuration or maintenance; a simple Qlik Sense variable is enough 😉 Learn more here.
The governance in Qalyptus is more advanced than NPrinting; you can define access and assign roles to users very finely (read, create, delete, execute, ...). You will love it! Learn more here.
Switching to Qlik Sense SaaS and Qalyptus Cloud will not impact recipients who receive reports generated from Qlik Sense for Windows and NPrinting.
Objective:
For this document, we will review how to setup a connection to an AWS S3 bucket using Qlik SaaS (Qlik Cloud Services and Qlik Sense Business).
AWS S3 Setup:
AWS IAM Configuration
Since Qlik SaaS uses IAM user accounts to connect to S3, we will create an IAM user who will have full control over the S3 bucket. An optional configuration will be outlined later which will create an IAM user who has only read rights to the bucket. This shows the ability of Qlik SaaS to inherit granular IAM rights to buckets. For example, creation of read and read / write users who are scoped to departments is possible an encouraged in Qlik SaaS.
AWS S3 Configuration
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"AWS": [
"arn:aws:iam::<myIAMuser>"
]
},
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::<myS3Bucket>"
},
{
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam::<myIAMuser>"
},
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::<myS3Bucket>/*"
}
]
}
Qlik SaaS Configuration
In Qlik SaaS, users can create data connections in two places: inside of a Qlik app or in the Hub. For this guide, we will use the Hub option.
Alternative Policy Configuration
As mentioned above, with AWS's Policy flexibility, we can create custom policies on the bucket which give a low level of granular control over which user(s) can do which actions on which files.
To provide two examples of this flexibility:
Option 1 - Read-Only vs. Read/Write Access
This policy provides for separation of read and read/write activities:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"AWS": [
"arn:aws:iam::<myReadUser>",
"arn:aws:iam::<myReadWriteUser>"
]
},
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::<myS3Bucket>"
},
{
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam::<myReadWriteUser>"
},
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::<myS3Bucket>/*"
},
{
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam::<myReadUser>"
},
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::<myS3Bucket>/*"
}
]
}
Option 2 - Root User vs. Read-Only Line of Business / Project / Department
This policy provides for a read-only user who is scoped to purely a specific "folder" for a department / project / line of business:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": {
"AWS": [
"arn:aws:iam::<myReadOnlyDepartmentUser>",
"arn:aws:iam::<myRootUser>"
]
},
"Action": "s3:ListBucket",
"Resource": "arn:aws:s3:::<myS3Bucket>"
},
{
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam::<myRootUser>"
},
"Action": [
"s3:GetObject",
"s3:PutObject"
],
"Resource": "arn:aws:s3:::<myS3Bucket>/*"
},
{
"Effect": "Allow",
"Principal": {
"AWS": "arn:aws:iam::<myReadOnlyDepartmentUser>"
},
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::<myS3Bucket>/<myDepartmentFolder>/*"
}
]
}
From the previous blog/video you have seen the ability to combine multiple data sets together to find my dream HDB home based on flat type, avg resale price, distance to the nearest MRT station and within 1km of a Primary School.
In this document I will show you how to add in an address to lookup the latitude longitude coordinate and then calculate the travel distance by car within 5, 10, 15 mins. These 2 actions can be initiated when doing the analysis and the results are calculated on the fly.
First, I will create 2 variables vAddress and vAddressPoint, and add in the variable input box and action button.
Next assign the vAddress to the variable input box so that when I type in the address to add a point, the address will be stored inside vAddress.
Next I will use GeoOperation AddressPointLookup to return me the AddressPoint by passing in the vAddress as input.
And then assign this as an action to the action button. Set the action to set variable value, variable to vAddressPoint and the value to the GeoOperation.
When I click on the action button, the AddressPointLookup function will return the latitude longitude coordinate of the address and stored inside vAddressPoint. I can then add this point onto the map as a point layer.
I will repeat this for the travel area: create 2 variables vTravelTime and vTravelArea, and add in the variable input dropdown and action button.
Next assign the vTravelTime to the variable dropdown and set the value to 5, 10, 15 and 20 mins. Remember to set the value to the actual value.
Next I will use GeoOperation TravelAreas to return me the TravelArea by passing in the vTravelTime and vAddressPoint as input.
And then assign this as an action to the action button. Set the action to set variable value, variable to vTravelArea and the value to the GeoOperation.
When I click on the action button, the TravelAreas function will return the shape of the TravelArea and stored inside vTravelArea. I can then add this point onto the map as an area layer.
This will be the end result.
Do refer to my other blogs:
Part 1 - Using Qlik Sense to find my dream home
Part 1a - How to build the base dashboard (Video)
Part 1b - How to build the base dashboard (Guide)
Part 2 - How to geocode a HDB block and Binning
Part 3 - How to calculate distance to MRT/LRT
From the previous blog/video you have seen the ability to combine multiple data sets together to find my dream HDB home based on flat type, avg resale price, distance to the nearest MRT station and within 1km of a Primary School.
In this document I will show you where to get Singapore Primary School information, how to calculate the 1km circle coverage of the school and which HDB unit falls within the 1km circle.
The information for Singapore Primary School is from https://data.gov.sg/dataset/school-directory-and-information
We can use RestfulAPI call to retrieve the information from https://data.gov.sg/api/action/datastore_search?resource_id=ede26d32-01af-4228-b1ed-f05c45a1d8ee&limit=100
As I only need Primary School so I will add in a filter where mainlevel_code='PRIMARY'. I have created another column to combine address, postal code and 'Singapore' to be used later to lookup latitude longitude coordinate. RowNo is also added to create a unique identifier for the Primary School.
Next I will use the GeoOperation AddressPointLookup to geocode the lookup column to the respective latitude longitude coordinate as return as PrimarySchoolPoint. (For more information on the operation AddressPointLookup do refer to https://help.qlik.com/en-US/geoanalytics/Subsystems/GeoOperationsService/Content/connector/connector...)
This will return a table containing both the Primary School information and the PrimarySchoolPoint.
Next for Singapore Citizen to register for a Primary School in Singapore, distance to the Primary School is taken into consideration. I will need to find out the 1km circle of all the Primary School if I want to have priority during school admission.
Next I will use the GeoOperation TravelArea to calculate the 1km circle by using the transportation="bird" option. This will draw a 1km circle regardless of the roads. If I need to calculate the distance by car I can change the transportation="car". (For more information on the operation TravelArea do refer to https://help.qlik.com/en-US/geoanalytics/Subsystems/GeoOperationsService/Content/connector/connector-geoanalytics_reference-Operation.htm)
This will return a table containing the PrimarySchoolID and the shape of the 1km circle.
I can then use GeoOperation Within to determine which HDB unit falls within the 1km circle of the Primary School. However, since the ScriptEval cannot take in 2 intable, I will need to store one of them into online storage and be referenced using the URL method. (For more information on the operation Closest and the use of URL do refer to https://community.qlik.com/t5/GeoAnalytics/GeoOperations-use-CLOSEST-with-two-loaded-tables/td-p/172...)
This will return a table containing the PrimarySchoolID and a list of HDB units that falls within the 1km circle.
I can then put all these data into the map. For e.g., if I select a Primary School, I will be able to see the 1km circle and all the HDB units that falls within.
Do refer to my other blogs:
Part 1 - Using Qlik Sense to find my dream home
Part 1a - How to build the base dashboard (Video)
Part 1b - How to build the base dashboard (Guide)
Part 2 - How to geocode a HDB block and Binning
Part 3 - How to calculate distance to MRT/LRT
From the previous blog/video you have seen the ability to combine multiple data sets together to find my dream HDB home based on flat type, avg resale price, distance to the nearest MRT station and within 1km of a Primary School.
In this document I will show you where to get the MRT/LRT information and how to calculate the nearest routes from HDB to the closest MRT/LRT stations.
The information for the Singapore MRT/LRT is from https://www.kaggle.com/yxlee245/singapore-train-station-coordinates
This is a screenshot of the data:
Next I will use the GeoOperation Closest to calculate the shortest distance between the HDB and the newly acquired MRT dataset. However, since the ScriptEval cannot take in 2 intable, I will need to store one of them into online storage and be referenced using the URL method. (For more information on the operation Closest and the use of URL do refer to https://community.qlik.com/t5/GeoAnalytics/GeoOperations-use-CLOSEST-with-two-loaded-tables/td-p/1721665)
I also get to know that if I use dropbox I will need to change the prefix www. to dl. and suffix dl=0 to dl=1 . (For more information on this do refer to https://community.qlik.com/t5/GeoAnalytics/GeoAnalytics-Shapefile-issue/td-p/1456366)
While running the GeoOperation I faced another issue, the dataset is too big to run. I will need to split the dataset into chunks of 100 and run it individual. (For more information on how to split up the data do refer to https://community.qlik.com/t5/Knowledge/Splitting-up-GeoAnalytics-connector-operations/ta-p/1715346 )
This will return a table containing the mapping of MRTID and HDBID, the distance and routes between the 2 points.
I can then use the routes to create a line layer in the map to show the path between the 2 points
Do refer to my other blogs:
Part 1 - Using Qlik Sense to find my dream home
Part 1a - How to build the base dashboard (Video)
Part 1b - How to build the base dashboard (Guide)
Part 2 - How to geocode a HDB block and Binning
Part 3 - How to calculate distance to MRT/LRT