We're using Coremetrics and GA through Tealium and CM allows us to define the test/dev through the tag, but it doesn't look like GA does.
If we have 1 account to capture all the prod data in GA, do we have to set up a separate tag to capture test data or is there a way to make sure that all test/dev data is going to the separate dev account through the original tag?
Great question. The best way to handle this is with one tag instance that makes use of a lookup table.
- create a new Data Source called "google_account"
- add a new Lookup table extension
- scope to Google Analytics
- Lookup Value In: select "domain"
- Destination: select "google_account"
- keep the other options as the default
- Lookup Match: enter a test domain e.g. www.tealium.com (no protocol or slashes)
- Output: enter the test Google account number
- move to the Tags tab
- "Edit" the Mapped Data Sources
- choose "google_account" from the drop-down
- click the "Select Destination" button
- when the Mapping Toolbox modal appears, select "Account (Override Default)"
- Save/Apply/Publish all changes
This will run the lookup table each time the Google tag runs and dynamically override the setting in the default tag configurations.
Thanks Dan, if we have multiple test environments, can we simply put in a semicolon in the lookup match so that it captures information from all those domains?
Conversely, might it be easier to create something that looks for just the production domain and then sends everything else to the test/dev account?
I am using SiteCatalyst App Measurement for JS, not the legacy H tag. Dynamic Accounts is not one of the current options for that template, correct? So would the Lookup Table approach be the best alternative?
Yes, the lookup table would be the best approach using the AppMeasurement tag. Then you would map the output variable back to s_account in the tag mappings.
One note about the lookup table would be to include the default output. Typically this could be the dev report suite. That way you only have to define your production domains in the lookup table and all other traffic, not on a production domain, will get defaulted to dev report suite.