Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!

Sending reports by email and receiving alerts using QlikView Publisher and QlikView Server or Desktop

No ratings
cancel
Showing results for 
Search instead for 
Did you mean: 
Sonja_Bauernfeind
Digital Support
Digital Support

Sending reports by email and receiving alerts using QlikView Publisher and QlikView Server or Desktop

Last Update:

Feb 10, 2023 3:53:11 AM

Updated By:

Sonja_Bauernfeind

Created date:

Mar 26, 2015 9:27:31 AM

QlikView Server, Desktop, and QlikView Publisher have a built-in email functionality in order to send alerts and notifications according to triggers, but the functionality is limited. Please review our more extensive offering using Qlik NPrinting or utilising Alerting in our Cloud offering.

Standalone, QlikView allows you to:

  • Send emails and distribute copies of a report on a schedule
  • Send alert emails when tasks fail (or are successful) 

Note that a Publisher license is required for most options.

This article is intended to clarify and elaborate on the differences and the different options that exist with sending emails from within the QlikView products. In general, only "Alerts" in QlikView Desktop are transferred with a document to QlikView Publisher, and in some scenarios user-made macros and third-party extensions. This means that this article only handles functionality that is part of the core product.

This article assumes that the reader has some knowledge about how to create tasks in Publisher, what NTLM, NTFS, SMTP, QVB and QDS stands for, how to create and open documents and e.g. the difference between a reload and/or a distribution.

 

QlikView Desktop

Mail settings

Under Settings > User Preferences > Mail, one can find the email settings for the QlikView Desktop program.

Sender - Can be set to pretty much anything, as long as the user account running the services is trusted by the SMTP server to send emails.
Server - Defines the SMTP server, which is usually outside QlikView control.
Authentication method - defines by which user account the client can send emails. "None" means anonymous, and NTLM is mostly used in older domains. If you get an error message when using NTLM as the authentication method, try "None". If you are using a Active Directory Domain, you are already logged on and authentication on the domain, and the computer is a member of the domain. This means that the SMTP server recognizes the address being used as well as the computer, which allows you to send emails. This also means that you do not need to run QlikView Desktop with a domain user account in order to send emails, but this can instead depend on what your domain policies and SMTP server allow.

Test mail

Built into this Mail setting tab inside "User Preferences" is also "Test", which allows you to send a test mail. Due to the architecture of the product there are a few differences that might impact how it behaves in your environment, e.g. Test mail works, but an email from a Macro, an alert or extension does not work. It can also depend on the user account running the document at the time being, and if it is logged in or not.

When do you use the email functionality in QlikView Desktop?

Most built-in functionality that uses the mail settings inside QlikView Desktop can be found under "Tools" > "Alerts". Here one can define an email to be sent during certain circumstances, due to certain triggers. This "Alerts" functionality will be activated if used on QlikView Publisher/Server, but the email will be sent by the QVB process instead of the QDS. Configuration of email settings can be done for the settings.ini of the QVB, located at C:\Windows\System32\config\systemprofile\AppData\Roaming\QlikTech\QlikViewBatch . Neither QlikView Desktop or the QVB support SSL for email alerts: you should therefore use other sorts of notifications and alerts if your SMTP server is SSL-only. As mentioned, there are more ways to configure email notifications, which can transfer some email notification settings to QlikView Publisher, available for further development outside the core functionality, e.g. by Macros (Tools > Edit Module) or Extensions (e.g. Settings > Document Properties > Extensions).

 

QlikView Publisher Settings

Mail settings

In the QMC, under System > Setup > Mail Server, one can find the email settings for the QlikView Distribution Service.

Location - Defines the SMTP server, which is usually outside QlikView control.
Miscellaneous - "From adress" can be set to pretty much anything, as long as the user account running the services is trusted by the SMTP server to send emails. E-mail format can be of choice, either plain or HTML.
Authentication method - defines by which user account the client can send emails. Anonymous does not try to authenticate towards the SMTP server, but works if the server is within the domain and/or the SMTP server allows anonymous emails to be sent. "Use Distribution Service account" let's you authenticate with the service account being used for the service, in case the SMTP server requires a domain account to be authenticated in order to send emails. Finally, "User name and password" lets you define custom credentials to an SMTP server. This is mostly used when using external mail servers like GMail and similar.

Override E-mail

For test purposes and not to spam other people's inboxes when doing tests, one can set a single email address to be used to receive all emails. Remember to change this back if being used.

Test mail

Built into this Mail Server settings tab is also "Send test e-mail". Due to the architecture of the product, there are a few differences that might impact how it behaves in your environment, e.g. Test mail works, but an alert email, a notification email or a distribution does not work. It can also depend on the user account running the document at the time being, and if it is logged in or not. The major difference, as of v11.20 SR10 is that the test email is sent by the QlikView Management Service and not the QlikView Distribution Service. If you have many servers used for QlikView in your environment, the test email might be sent from a different server than the alert email. The test functionality is also using a simple .NET SMTP client, and do not use the DSC to look up an email address, it just takes the email and sends it.

Document Administrators Authorized to Distribute via E-mail

Some users can be set to be QlikView Publisher Document Administrators, which are allowed to distribute documents via e-mail. 

QDS settings

You may find general QDS setting for alert and notification emails under QMC > System > Setup > Distribution Services > QDS@servername. There are two tabs here, "Alert E-mail", which let's you define which system administrators who should receive an alert email whenever a distribution has a warning or an error. On the next tab you can define "E-mail templates", for attachments, notifications and alerts. The different types of emails is explaining in the next section. The email templates can be customized with different variables, found in Help, in the upper right corner. As of 11.20 SR6 and later, a few new variables have been added, e.g. [TaskLogHyperlink], [DocumentLogHyperlink] and [DocumentLog]. 

 

Different types of mails in QlikView Publisher:

 

Distribution of Documents/PDF

For this to work, a Publisher needs to be authorized to send PDFs, which is determined by the license, e.g. :
PDF_GENERATION;YES;;
QlikView Information Access Server and QlikView Extranet Server does not have this in their licenses. The QlikView Distribution Service is responsible for the email being sent in this feature, where the QDS gets a recipient list and looks it up with the help of the DSC. The recipients emails are based on their ID (e.g. DOMAIN\username) or a plain name (e.g. account@mail.com). This process also validates the email address to ensure it is valid. The email will contain the text template defined within the QDS settings with the PDF/QVW attached. The email distribution setting is to be found on the same tab as "Distribute to server" or "Distribute to folder":

 

Distribution of Documents by email.png

The QDS can distribute a PDF or a QVW to email addresses at the same time as it becomes available on the AccessPoint, meaning distribution is not limited to a single type of publication. The type of document of choice, a report via PDF or the full document via QVW, can be set under the "File Typ" subtab. Depending on the size of the QVW, limitations on the filesize may be subject to mail server settings. If you do not get the option to specify users or groups, no Mail Server has yet been configured.

Notification emails

Done by the QDS as well, with the same mechanism. When setting up a document in QlikView Publisher, one can configure a notification to be set, so that specific users are notified when there is a new version of a document on the AccessPoint. Under QMC > Documents > Source Documents > Document > Taskname (assumes the task has already been created) > Distribute > Notify, you can check whether or not the e-mail recipients should receive a notification or not.

 

Notify e-mail settings.png


This is not intended to use for distribution, only notification, meaning the "Distribute via E-mail" does not need to be used, instead the end-user get's a notification when a document is distributed to a QVS or a folder. If there is an email-distribution as well, it is redundant to first send the QVW/PDF via email and subsequently an email with a notification, meaning no notification will occur. A major difference to the "Distribution via E-mail" is that the notification functionality uses a queue system, where the thread runs every 30 seconds to send mail.

Alerts/Error in reloads

The email functionality that is used most by far in QlikView Publisher, is the "Alerts email". Using a template defined in the QDS setting, the QDS sends an email to defined recipients in case of a failing task. After a task fail, the QDS runs a cleanup method where it checks if "Alerts" have any recipients. The recipients list, which mostly consists of QlikView Server Administrators, can be set in the QDS Settings > Alert "E-mail":

alert email to system administrators.png

 

For every task that is failing an email would be sent to the full list of administrators, along with an excerpt of the error message. The alert email functionality uses the same functionality as "Distribute via e-mail" and "Notification", meaning the QDS gets a recipient list and looks it up with the help of the DSC. The recipients emails are based on their ID (e.g. DOMAIN\username) or a plain name (e.g. account@mail.com).

QlikView Server Settings

Mail settings

In the QMC, under System > Setup > Mail Server, one can find the email settings for the QlikView server program.

Location - Defines the SMTP server, which is usually outside QlikView control.
Miscellaneous - "From adress" can be set to pretty much anything, as long as the user account running the services is trusted by the SMTP server to send emails. E-mail format can be of choice, either plain or HTML.
Authentication method - defines by which user account the client can send emails. Anonymous does not try to authenticate towards the SMTP server, but works if the server is within the domain and/or the SMTP server allows anonymous emails to be sent. "Use Distribution Service account" let's you authenticate with the service account being used for the service, in case the SMTP server requires a domain account to be authenticated in order to send emails. Finally, "User name and password" lets you define custom credentials to an SMTP server. This is mostly used when using external mail servers like GMail and similar.

Override E-mail

For test purposes and not to spam other peoples inboxes when doing tests, one can set a single email address to be used to receive all email. Remember to change this back if being used.

Test mail

Built into this Mail Server settings tab also "Send test e-mail". Due to the architecture of the product there are a few differences that might impact how it behaves in your environment, e.g. Test mail works, but an alert email, a notification email or a distribution does not work. It can also depend on the user account running the document at the time being, and if it is logged in or not. The major difference, as of v11.20 SR10 is that the test email is sent by the QlikView Management Service and not the QlikView Distribution Service. If you have many servers used for QlikView in your environment, the test email might be sent from a different server than the alert email. The test functionality is also using a simple .NET SMTP client, and do not use the DSC to look up an email address, it just takes the email and sends it.

Document Administrators Authorized to Distribute via E-mail

Some users can be set to be QlikView Server Document Administrators, which are allowed to distribute documents via e-mail. You can ready more about Document Administrators in the QlikView Server Reference Manual, see here .

QDS settings

You may find general QDS setting for alert and notification emails under QMC > System > Setup > Distribution Services > QDS@servername.

There are two tabs here, "Alert E-mail", which let's you define which system administrators who should receive an alert email whenever a distribution has a warning or an error.

On the next tab you can define "E-mail templates", for attachments, notifications and alerts.

The different types of emails is explaining in the next section.

The email templates can be customized with different variables. See E-mail Templates for details.





Troubleshooting

I do not get any alert e-mails, but the test-email functionality works!

Test-email does not confirm the email-addresses being used in the test, it simply sends an email. The alert email functionality matches the email address with the DSC to look it up. If you can't look up the email address under "Users", it might be possible that resolving email addresses is not working properly. You may also try to change the mail server authentication method from .e.g "Use Distribution Service account" (which might not have an email-address registered, is not allowed to send emails or does not have an account at the SMTP server), to the "Anonymous" checkbox. Some SMTP servers allows anonymous emails which could simplify sending emails. Using an account does thus force authentication towards the SMTP server which it doesn't accept.

If you use port 465 or 587 for port under Location, change the QVManagementService.exe.config that is located at C:\Program Files\QlikView\Management Service.  You will need to change <add key="UseSSLForSMTP" value="false"/> from false to true. Change the QVDistributionService.exe.config that is located at C:\Program Files\QlikView\Distribution Service. You will need to change <add key="UseSSLForSMTP" value="false"/> from false to true.

I do not get any notification emails!

Wait for at least 30 seconds and see if it was in the outbox. If sending a lot of emails it might take some time before the email reaches the end-user. The advice here would be to wait a further 10 minutes to confirm it is just not a delay on the mailserver end. Confirm that the issue solely is located to notification emails by trying to distribute a document via email.

Labels (1)
Comments
john_oll
Partner - Creator
Partner - Creator

Hello Sonja,
for
QDS settings
the link to the pdf is broken.
Would be nice if you could add the full information about the variables into the article.
Thanks!

Sonja_Bauernfeind
Digital Support
Digital Support

Hello @john_oll 

I added a link to the Help site directly and removed the refs to the old release notes. E-mail Templates - is that what you were looking for?

All the best,
Sonja 

john_oll
Partner - Creator
Partner - Creator

Hello @Sonja_Bauernfeind ,
thanks a lot!
Different question:
Do you know the storage location for the edited Email template?
You can only edit it with publisher, so customers without publisher have no option to edit it.
Thanks!

Sonja_Bauernfeind
Digital Support
Digital Support

That is an excellent question.  It's been a while since I worked directly in QlikView but I faintly remember answering this - many many years ago.

Let me try and dig up the information!

All the best,
Sonja 

Sonja_Bauernfeind
Digital Support
Digital Support

@john_oll 

Success!

I made a change, sorted all files in my QlikView directory by last edit, and found it in the QVPR:

mail template storage.png

So they are stored along with all the other settings the QVPR takes care of, in the c:\programdata\qliktech\managementservice\QVPR directory and the MailTemplate file.

Hope this helps!

All the best,
Sonja 

 

john_oll
Partner - Creator
Partner - Creator

Thanks @Sonja_Bauernfeind for figuring it out 🙂

Contributors
Version history
Last update:
‎2023-02-10 03:53 AM
Updated by: