Quantcast
Channel: Transact-SQL forum
Viewing all articles
Browse latest Browse all 23857

Column Store Index in SQL SERVER 2012

$
0
0

Hey Folks,

Hope you all are doing well there.

Here i come again with one of the intresting query , it would be really appreciable if any one have solution for the same.

My query is

As you all know, Column store Index is newbie to SQL SERVER and get introduced in SQL SERVER 2012, i have question based on the same.

Problem 

I have table say Table A having column ColA,ColB and ColC.

-----------------------------------------------------

Data Type

ColA - BIGINT

ColB - NUMERIC(22,2)

ColC - INT

Primary Key

Composite primary key of (ColA and ColB)

----------------------------------------------------

Now when i am trying to create ColumnStore index based on ColA and ColB, i am getting below error

CREATE INDEX statement failed. A columnstore index cannot include a decimal or numeric data type with a precision greater than 18.  Reduce the precision of column 'ColB' to 18 or omit column 'ColB'.

Please let me know, how to create Column Store index based on these columns

Note

1. It is mandatory for ColB to have Data type defined NUMERIC(22,2), cant tweek or change at table level.

2. As per ColumnStore index, it is mandatory to include all the primary key in Column Store definition

3. It is business requirement to include ColA and ColB as a Primary key.

Please let me know the solution, how to create Column Store index based on above condition.

Many Thanks  


Amit
Please mark as answer if helpful
http://fascinatingsql.wordpress.com/





Viewing all articles
Browse latest Browse all 23857

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>