Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Change Page Number to extract information from Tableau Server

Kuldeepmathur
8 - Asteroid

HI All,

 

I am working on a workflow to update my Tableau server Group with the help of Alteryx. I have overall 1094 Users in my Tableau server but I am only able to extract 1000 users information as it is an API restriction therefore How I can get the rest 94 users information?

 

I tried to change the page number as well but not getting required result.

 

Thanks,

Kuldeep

 

 
 

 

 

 

 

 

4 REPLIES 4
Prometheus
12 - Quasar

@Kuldeepmathur This sounds like a use case for creating a batch macro. If you can identify the part of the URL that needs to change for each API call, then you can have it run until you have all your users.

Kuldeepmathur
8 - Asteroid

Thanks for the reply :) Do you have any Macro ready as an example?

Prometheus
12 - Quasar

@Kuldeepmathur I was reading up on Tableau REST APIs (https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_concepts_paging.htm) and it says here that you can change the page number. If you can't change the page number by just creating two data streams with one Formula tool that has [server] + "/api/3.17/sites/" +[site_id] +'/users?fields=_all_&pageSize=1000&pageNumber=1' in it and another Formula tool that has [server] + "/api/3.17/sites/" +[site_id] +'/users?fields=_all_&pageSize=1000&pageNumber=2' in it, then you can turn your whole workflow into a batch macro where the value that goes into it at the Control Parameter is the page number. The batch macro will send [server] + "/api/3.17/sites/" +[site_id] +'/users?fields=_all_&pageSize=1000&pageNumber=1' first and get your results then it'll run [server] + "/api/3.17/sites/" +[site_id] +'/users?fields=_all_&pageSize=1000&pageNumber=2' and get your results.

 

I attached a simple batch macro as an example, in case you've never used or created a batch macro. This macro queries a database that has both hot and iced coffee drink names, descriptions, and recipes. If you pull this macro into a workflow and input a single field with just the values "hot" and "iced" in a column, it'll return all the drinks that are hot and the drinks that are iced by changing the URL. 

Kuldeepmathur
8 - Asteroid

Sorry for the late reply Prometheus! Thank you so much.

Labels