marketerone
marketerone 12 Dec 2020
2

Up next

How to Add Incoming Invoices to your VAT return
26 Jan 2021
How to Add Incoming Invoices to your VAT return
Lovat Compliance LTD · 379 Views

How to Return Profit for Current and Previous Year Using a Parameter in Tableau

Is this your company's video?
857 Views

In this silent video you’ll learn how to return the profit for current and previous year using a parameter to choose current year in Tableau.

Read the full article here: Returning Profit for Current and Previous Year Using a Parameter — https://kb.tableau.com/article....s/howto/returning-pr

- - - - - - - - - - - - - -

STEP 1 - CREATE THE PARAMETER
1. Right-click the Parameters pane and select Create Parameter....
2. Name the parameter This Year.
3. Under Data Type select Integer.
4. Under Allowable Values select List.
5. Enter 2010, 2011, 2012, and 2013 in the list of date values.
6. In the Display Format drop-down menu, select Number(Custom).
7. Enter 0 for the number of decimal places.
8. Clear the selection for Display thousands separator.
9. Click OK.
10. Right-click This Year and select Show Parameter Control.


STEP 2 - CREATE THE CALCULATED FIELDS
1. Go to Analysis and then Create Calculated Field....
2. Name the calculated field This Year Profit.
3. In Formula enter IF YEAR([Order Date]) = [This Year] THEN [Profit] END.
4. Repeat steps 1-3 with name Last Year Profit and formula IF YEAR([Order Date]) = [This Year] - 1 THEN [Profit] END.


STEP 3 - BUILD THE VIEW
1. Drag Customer Segment to the Rows shelf.
2. Drag This Year Profit to the Column Shelf.
3. Drag Last Year Profit to the Column Shelf.


Related solutions:
Parameter Actions — https://help.tableau.com/curre....nt/pro/desktop/en-us
Create Parameters — https://help.tableau.com/curre....nt/pro/desktop/en-us


- - - - - - - - - - - - - -

Subscribe to the Tableau YouTube channel here: [link: http://www.youtube.com/subscri....ption_center?add_use

Free Trial of Tableau: [link: https://www.tableau.com/products/trial ]

Show more

About marketerone


0 Comments sort Sort By

Up next

How to Add Incoming Invoices to your VAT return
26 Jan 2021
How to Add Incoming Invoices to your VAT return
Lovat Compliance LTD · 379 Views