I am working on a viz that has two data sources linked to Google Analytics, each of which uses different measures (users, sessions, pageviews and transactions for one, and quantity in the other). I want to combine both into a single map view, and allow the user to select teh domain first and then the dimensions appropriate to each one.
I've set up a parameter to switch between the two domains, and then set up a calculated field based on the parameter selection to use as the filter. I've tried the following code in the calculated field -
IF [Domain] = 'Domain1' THEN 'Users'
ELSEIF [Domain] = 'Domain1' THEN 'Sessions'
ELSEIF [Domain] = 'Domain1' THEN 'Pageviews'
ELSEIF [Domain] = 'Domain1' THEN 'Transactions'
ELSEIF [Domain] = 'Domain2' THEN 'Quantity'
- but this only shows Users for Domain1 and Quantity for Domain2. Is there a way to build up a list of options so when Domain1 is selected each of the options is displayed in the filter list? Or, is there a simpler way of doing this altogether...?
oh, hi Mark.
The way you have it coded, once it hits the 1st Domain that matches it will stop processing. You'll need to find another way to gather your measures.