{"id":37,"date":"2007-11-13T22:46:58","date_gmt":"2007-11-14T03:46:58","guid":{"rendered":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/37_customizing-object-names-in-analysis-services-database-using-translations"},"modified":"2008-03-17T20:49:07","modified_gmt":"2008-03-18T01:49:07","slug":"customizing-object-names-in-analysis-services-database-using-translations","status":"publish","type":"post","link":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/37_customizing-object-names-in-analysis-services-database-using-translations","title":{"rendered":"Customizing object names in Analysis Services database using translations"},"content":{"rendered":"<p>For the past few years I\u00a0was working on data warehouse project that is customized and installed for different clients. As part of customization, sometimes clients might request to use different names for dimensions, attributes or measures. For example in Geography dimension for US\u00a0customers that do business just in US\u00a0you would want to have hierarchy Country-State-City, but\u00a0for Canadian customer\u00a0the same hierarchy would be Country-Province-City. For customers that do business in US and Canada, the same hierarchy could be called Country-State|Province-City.<\/p>\n<p>Analysis Services 2005 provides easy interface to rename dimensions, attributes or measures.\u00a0But things become more complicated when these object names are\u00a0used in cube MDX script &#8211;\u00a0these renames can break script. Instead of renaming actual object, you might consider using &#8220;Translation&#8221; feature of Analysis Services 2005.\u00a0I usually create translation for language that matches clients PCs language. This way Excel 2007 uses translated names without any additional steps. For other SSAS clients you might have to specify locale ID in connection string parameter, example:\u00a0&#8220;Language Identifier=1033;&#8221;. With translations you can choose to rename just a few\u00a0objects. If no translations exists, Analysis Services uses default object name assigned during object creation.<!--more--><\/p>\n<p>Here is a quick example on how to rename a few attributes in Adventure Works database. This is how Geography translation tab looks with shipped version of Adventure Works database:<\/p>\n<p><img loading=\"lazy\" width=\"557\" src=\"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/BlogFiles\/Post37\/DimTransTab.jpg\" alt=\"Dimension Translation Tab\" height=\"413\" style=\"width: 557px; height: 413px\" title=\"Dimension Translation Tab\" \/><\/p>\n<p>I\u00a0added translation for &#8220;State-Province&#8221; and &#8220;Postal Code&#8221; attributes and rename them to &#8220;State&#8221; and &#8220;Zip&#8221;:<\/p>\n<p><img loading=\"lazy\" width=\"644\" src=\"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/BlogFiles\/Post37\/GeographyTranslation.jpg\" alt=\"Geography Dimension Translation\" height=\"352\" style=\"width: 644px; height: 352px\" title=\"Geography Dimension Translation\" \/><\/p>\n<p>After deploying this change to there server, there are results in Excel 2007:<\/p>\n<p><img loading=\"lazy\" width=\"465\" src=\"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/BlogFiles\/Post37\/RenameResults.jpg\" alt=\"Results in Excel 2007\" height=\"479\" style=\"width: 465px; height: 479px\" title=\"Results in Excel 2007\" \/><\/p>\n","protected":false},"excerpt":{"rendered":"<p>For the past few years I\u00a0was working on data warehouse project that is customized and installed for different clients. As part of customization, sometimes clients might request to use different names for dimensions, attributes or measures. For example in Geography dimension for US\u00a0customers that do business just in US\u00a0you would want to have hierarchy Country-State-City, [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[4],"tags":[],"aioseo_notices":[],"_links":{"self":[{"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/posts\/37"}],"collection":[{"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/comments?post=37"}],"version-history":[{"count":0,"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/posts\/37\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/media?parent=37"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/categories?post=37"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.ssas-info.com\/VidasMatelisBlog\/wp-json\/wp\/v2\/tags?post=37"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}