Discussion board where members can learn more about Qlik Sense Data Connectivity.
I need to use DELETE method in Qlik Sense REST API connection. When I am creating the data connection, it gives options for only GET and POST. Is there any way to use DELETE method in Qlik Sense ?
Looking forward to the replies!
Thanks and Regards,
By default, the Qlik Sense Rest Connector doesn´t provide data manipulation, only read data:
"The Qlik REST Connector enables Qlik Sense and QlikView to efficiently load data into Qlik apps from a REST data source"
you can't set up DELETE method directly in connection but you can override POST method using solution presented below (HTTPHEADER "X-HTTP-Method-Override" "DELETE", ).
I use it in scripts calling NPrinting API via Qlik RESTFull connector (look here if you are interested)
Let vDeleteUserURL = 'https://$(vNPrintingServer):4993/api/v1/users/'&'$(vUserId)'; Trace Deleting user: $(vDeleteUserURL);LIB CONNECT TO '$(vConnection_POST)';RestDeleteUserTable:SQL SELECT"__KEY_data"FROM JSON (wrap off) "data" PK "__KEY_data"WITH CONNECTION( URL "$(vDeleteUserURL)",HTTPHEADER "Content-Type" "application/json", HTTPHEADER "X-HTTP-Method-Override" "DELETE", HTTPHEADER "cookie" "$(vCookie)");
Thanks for you reply!
The name of this connector is wrong!How can you name a connector "REST" and do not allow all the Representational State Transfer methods?
It should be called "only read REST".