Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi folks
I wanted to know if there is a way to create a Data Connection (PostgreSQL) through automations.
Thanks in advance.
Julian
Yes, you can use the Qlik Platform Operations connector to create the connections with native blocks, or you can send the request to create the connection with the Qlik Cloud Services connector with raw blocks.
There is a tutorial here: https://qlik.dev/manage/data-connections/create-data-connections/
And examples here (albeit not for Postgres): https://qlik.dev/examples/manage-examples/data-connection-create/
What auth are you using for your connection? We might be able to help steer you.
Sorry for the late response, i'm trying to create the connection for multitenant but i don't know how i can set up the parameters like user/password in Connection properties
If you can help me, i would appreciate it.
Thanks in advance
Julian
Hi Julian,
The connection properties field (in the bottom of your screenshot) is used to send the configuration of the connection you want to create, so within this bit is where you would add information such as username/pass credentials
An example for you could be:
"connectionProperties":
{"host": "<HOST>",
"port": "<PORT>",
"database": "<DATABASE_NAME>",
"username":"<USERNAME>",
"password": "<PASSWORD>"
}
Unfortunately, Qlik do not have examples of every type of data connection so you'd need to create the data connection manually (the way you'd like it to be configured or a similar example), and then perform an API call to retrieve that data connection, which will then show the different connectionProperty parameters you can to add into that field in the Automation
The example is from the following: https://qlik.dev/examples/manage-examples/data-connection-create/#:~:text=This%20example%20connects%....