-
1. Re: Create dropdown date parameter
Jim DehnerMar 10, 2018 4:34 AM (in response to Deepika Goyal)
Good morning
without seeing your workbook I think you created your parameters using the Range" radio button
see below
If you edit the parameter and use the List radio button it will change the parameter as shown below
Then when you open it it will give you a drop down
Jim
If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution. Thank you.
-
2. Re: Create dropdown date parameter
Zach Leber Mar 10, 2018 4:40 AM (in response to Deepika Goyal)Hi Deepika, select your sales date field and create two date parameters from it. Change their formatting to custom "mmm yyyyy" to get them to months, okay the warning about repeat values.
Then add your sales date to the filter shelf, change it to discrete, and add a condition that compares the month of the date with your two parameters.
Final view could look like the following:
Regards,
Zach
P.S. Tableau 10.3 TWBX attached.
-
MonthBook1.twbx 437.3 KB
-
-
3. Re: Create dropdown date parameter
Deepika Goyal Mar 10, 2018 5:46 AM (in response to Zach Leber) -
4. Re: Create dropdown date parameter
Zach Leber Mar 10, 2018 8:45 AM (in response to Deepika Goyal)Try filtering on Month instead of MONTH(Month). You can still show MONTH(Month) in your view.
Tableau Desktop 10.3 or higher will open the 10.3 TWBX I attached.
Your example shows a range of months, in that case change the Filter Condition to:
DATETRUNC('month', [Order Date])>=
DATETRUNC('month', [Order Date 1])
AND
DATETRUNC('month', [Order Date])<=
DATETRUNC('month', [Order Date 2])
Please extract some of your data into a packaged workbook and attach a TWBX if you are still having trouble.
-
MonthBook2.twbx 444.7 KB
-
-
5. Re: Create dropdown date parameter
Lalitha B Mar 10, 2018 9:24 AM (in response to Zach Leber)1 of 1 people found this helpfulHi Zach,
I tried the solution provided and it worked for me only when filter is on Individual Dates as shown in the below screenshot.
Initially I tried using month option but it thrown error as mentioned by @Deepika in the previous reply.
I would like to know the reason why it works only with "Individual dates" option but not other options provided.
Thanks in advance
Regards,
Lalitha
-
6. Re: Create dropdown date parameter
Zach Leber Mar 10, 2018 9:59 AM (in response to Lalitha B)Hi Lalitha, in your list, the top two choices are green (continuous) which is why they don't work, and all the other choices convert the date to a datepart that you can't reference in the condition. But it's not a limitation, as you can use DATETRUNC or DATEPART in the Filter Condition to round the exact individual date any way you want (as in my example), and you can still set the date rounding in the view (also in my example). Regards, Zach
-
7. Re: Create dropdown date parameter
Zach Leber Mar 10, 2018 10:01 AM (in response to Lalitha B)Thank you Lalitha for pointing out that you need to select "Individual Dates" to use the filter condition I showed, I neglected to mention that and you can't tell from either my pictures or workbooks that that's what you have to do to set things up.
-
8. Re: Create dropdown date parameter
Zach Leber Mar 10, 2018 10:46 AM (in response to Deepika Goyal)Hi Deepika, back to your original requirement of providing drop-down menus for start and end, there's no way to do that without parameters. Nor can you show two separated months as in my first example. But a big downside of parameters for dates or any dynamic dimension is that they don't update with the correct choices for the latest data if you have live data. That's why filters are nice. I attached an example that uses a built in range filter on continuous MONTH(date). I agree that it's harder to choose the date with a slider than with a menu, but I found it handy that you could click the date and type the month/year which is even faster. I attached MonthBook3.twbx (10.3) which has all three examples posted above. Regards, Zach
-
MonthBook3.twbx 462.6 KB
-
-
9. Re: Create dropdown date parameter
Deepika Goyal Mar 10, 2018 10:02 PM (in response to Zach Leber)Hi Zach,
This worked for me!! Thanks a lot.
One thing, the dates we are showing in the paramter, after converting them to the customer (mmm yyy) they are not appearing in the order.
Also, i have to create one simple chart based on date1 and date option
Sales on Date1, sales of date2, MOM comparison ( perc)
I tried the option of table calculation but its not returning me all the three columns.
Any suggestion on this?
Regards,
Deepika
-
10. Re: Create dropdown date parameter
Zach Leber Mar 11, 2018 6:15 AM (in response to Deepika Goyal)You're welcome Deepika. Please mark some of the comments as helpful or correct and the question as resolved.
If the dates in your data source are not sorted, you can copy them to Excel, sort them there, and then paste them back into the parameter creation screen using the Paste from Clipboard option.
How do you want to display a third column that is a percent difference next to two columns that show sales? I've attached one example using a dashboard to show two different views next to each other, you could format that further. I needed to manually edit the axis limits and colors to make it work at all. I don't think it's the right way to display the data because your percentages could be even larger, e.g. 200% so how do you notice that vs. 100% without making the axes 500%?
If you are only comparing two months of sales that are represented by bars, you don't need any additional graphics, as there's no better visual comparison than two bar lengths. Maybe just add a numerical percent label, like this, which also works well when you are displaying more than two months.
-
MonthBook4.twbx 509.5 KB
-
-
11. Re: Create dropdown date parameter
Deepika Goyal Mar 11, 2018 10:00 AM (in response to Zach Leber)Hi,
I am not able to export your workbook, using 10.2.
Is there any workaround for sharing the workbook.
Regards,
Deepika