PowerPivot Multiple columns in primary table require reference to lookup table -- alias equivalent?

eohippus

New Member
Joined
Nov 8, 2008
Messages
2
If I have two fields in a primary table that relate back a country code lookup table, such as Origin_Country and Destination_Country and I would like to look up the country name for Origin_Country and Destination_Country for use in PivotTables, is there any way to create the equivalent of an Alias table in PowerPivot (without importing a second table) that would generate Origin_CountryName and Destination_CountryName values, or correlate all of my country codes to a single reference table?

I wasn't sure whether there was any way to accomplish this that doesn't cause performance issues, but I would like to display the country name values for PowerView outputs that use both fields. Is there any reasonable way to do this in PowerPivot (or worst case create calculated fields that looks up the value from the country code table for the country name)? I have lots of these types of lookups for Origin_Region, Destination_Region and the like, so would love to find a lightweight solution. Or is the most efficient option simply to import an Origin_Country lookup and Destination_Country lookup (I am just concerned this would be an issue for larger reference tables) and/or should I just do all of this before importing to PowerPivot?

Thanks in advance
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)
I tend to import a second table, but you could try adding a calculated column and pull in that value using LOOKUPVALUE

=LOOKUPVALUE(Country[CountryName],Country[COuntryyCode],[Destinationation_Country])
 
Upvote 0

Forum statistics

Threads
1,223,909
Messages
6,175,310
Members
452,634
Latest member
cpostell

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top