2 Replies Latest reply on May 7, 2013 4:56 AM by Jurien Groot

    Mass workbook publishing - dynamic parameter

    Jurien Groot

      I have a database connection where I filter based on a customer ID.

       

      I'd like to use customer ID as a parameter, to dynamically filter on the correct customer ID.

       

      Now, I have for example 100 customer ID's. I like to automatically create 100 workbooks (with 100 different extracts) for each specified customer ID and eventually publish these 100 workbooks to Tableau server with one push on the button.

       

      Is there any way to accomplish this? I didn't see an option with Tabcmd to adjust the dynamic parameter in a DB connection.

        • 1. Re: Mass workbook publishing - dynamic parameter
          Russell Christopher

          Hi Jurien -

           

          TabCmd does not allow you change the default value of a parameter when you use it to publish a workbook. The group of customers I work have very similar requirements to yours and generally approach the problem in one of two ways:

           

          Easy:

           

          • They write their reports using a Data Source which leverages User Filters in other words, they allow Tableau Server to automatically filter out rows based on the identity of the user logging into server.

           

          More Involved:

           

          • In their workbook they hard-code a "token" value for the parameter and/or filter. For example, CustomerId 999999 - a value that will never be used in the "real world" and is obviously "fake"
          • They write a little bit of Python / Ruby / <Insert language of your choice> to open up the twb  (which is nothing more than an XML file) and replace 999999 with a real customer id.
          • The code then saves the file with a different name
          • The code optionally calls tabcmd to publish the workbook to Tableau Server

           

          My people generally decide to use technique #1 vs. #2 based on how many users they'll be dealing with and the relative administrative overhead they'd look at to keep all of "their" users inside Tableau.

           

          Keep in mind that Tableau doesn't officially support hacking the XML in a twb, so you'll be on your own in that regard - but it's quite easy to do and anyone with a little bit of technical know-how should have no problems taking this on.

           

          Good luck!

          1 of 1 people found this helpful
          • 2. Re: Mass workbook publishing - dynamic parameter
            Jurien Groot

            Thanks for pointing out a couple directions. I will start playing with it