SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2008 Forums
 Analysis Server and Reporting Services (2008)
 SSAS - The sort order specified for distinct count
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

malachi151
Posting Yak Master

142 Posts

Posted - 06/29/2012 :  13:21:22  Show Profile  Visit malachi151's Homepage  Reply with Quote
When trying to process a cube after adding a Distinct Count measure I get the following error:

The sort order specified for distinct count records is incorrect.

I've read that this is typically caused by different collations on the SQL Server and SSAS server. I've gone ahead and changed the collation on the SQL Server from SQL_Latin1_General_CP1_CI_AS to Latin1_General_CI_AS. The collation on the SSAS server is Latin1_General.

Even after these changes and refreshing the DSV, and deleting and re-adding the measure, etc. I still get the error.

Any ideas?

--------------------------------------------------
My blog: http://practicaltsql.net/
Twitter: @RGPSoftware

malachi151
Posting Yak Master

142 Posts

Posted - 07/03/2012 :  11:40:17  Show Profile  Visit malachi151's Homepage  Reply with Quote
I figured this out. The problem was that even after setting the collation on the SQL Database to match that on the SSAS server, there was stil a conflict due to the fact that the column being used was a varchar instead of an nvarchar. It was resolved simply by casting the column to nvarchar in the calculated column that the distinct count is built on.

--------------------------------------------------
My blog: http://practicaltsql.net/
Twitter: @RGPSoftware
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.03 seconds. Powered By: Snitz Forums 2000