SQL Server Developer Center > SQL Server Forums > SQL Server Analysis Services > Error message "Cannot have more than 32 columns" while adding a table with more than 32 columns in PK to DSV
Ask a questionAsk a question
 

AnswerError message "Cannot have more than 32 columns" while adding a table with more than 32 columns in PK to DSV

  • Friday, October 23, 2009 6:38 AMsanjeev421 Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    I have a table in Sybase IQ.  It has 40 columns in its PK. When creating a CUBE and adding this table to DSV , I get the error message "Cannot have more than 32 columns". When I remove the PK, it gets added to DSV.
    Is there any resolution to this.

Answers

  • Friday, October 23, 2009 9:03 AMDarren GosbellMVP, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer
    I'm guessing that with a 40 column key, this is most likely a fact table. If this is correct, then SSAS does not need to have a PK defined in the DSV. So if you can take it off, or use something like a view (if Sybase IQ supports those) then I don't think there should be a problem.
    http://geekswithblogs.net/darrengosbell - please mark correct answers

All Replies

  • Friday, October 23, 2009 8:28 AMAshokDugaputi Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     

    SQL Server 2005 or 2008 supports only 16 columns as Primary key in a fact table. Similarly Analysis services is having some limitation of 32 PK columns?

  • Friday, October 23, 2009 9:03 AMDarren GosbellMVP, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     Answer
    I'm guessing that with a 40 column key, this is most likely a fact table. If this is correct, then SSAS does not need to have a PK defined in the DSV. So if you can take it off, or use something like a view (if Sybase IQ supports those) then I don't think there should be a problem.
    http://geekswithblogs.net/darrengosbell - please mark correct answers
  • Wednesday, November 04, 2009 6:49 PMsanjeev421 Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Yes this is a fact table. But even the View is not working. It gives the same message and I can not remove the PK. 
    I have found the solution as to make a named query instead of importing the table in DSV. In this way it siply ignores the PK and works fine.
    Thanks for your comments.