1 of 1 people found this helpful
So you have a data source # A and now you to do a comparison between current year sales and prior year sales by month you duplicated the data source which lets call B. If you do this and do an extract it willhave the data extracts of both A and B. Remember you would have duplicated the data but from a Tableau Perspective it's two data sources having same data. Now what's lingering in my mind is why do you duplicate the whole data source if you want to compare two or three fields? Just duplicate the fields instead of the whole data source. Again I may not be understanding the whole picture of what you are trying to achieve. But I am throwing my two cents.
Thanks for your response, Anoop. I used a duplicated data source to avoid having to create a number of calculated fields to achieve the same result. My understanding was that it would only create additional metadata pointing to the original extract, not an additional extract. But it sounds like I was incorrect, and an additional extract will always be created when a duplicate data source is used. So perhaps I should work creating calculated fields in the original data source instead.
Good Luck and let us know how it went.
Do mark this thread answered once you have your answer. Thanks.
I was able to use a table calculation, lookup([Sales], -12) to get the monthly sales from the prior year, but this is only useful without additional filters applied. If I want to show prior sales for 2016 only, this approach won't work, since the table will be filtered before the calculation is done, and the lookup will return nothing. Any ideas on how I can get around this?
The only other approach I can think of is to do the prior year calculations in the SQL used to pull the data (data source is Oracle), but I'd love to know if there are better ways.
2 of 2 people found this helpful
If you look at my response here
there are 2 ways to achieve what you need (One is to hide, rather than filter the years, or the niftier use of a Table Calc filter, which requires less/no maintenance)
Hope that helps.
Hi, Simon. I was not aware that data values could be hidden like that -- perfect! And maybe I'll give the table calc filter a shot too. Thanks very much for your help!
No problem...The reason I tend to use Table Calc filters for this, is that you are hiding, say, the year 2015...which means that next year you'll need to re-visit the model (..and more challenging...remember to re-visit the model!!) and hide 2016. The Table Calc filter lets it always just show, for example, the last year.