问:sql
Hi,ide
I have a table workcachedetail with 40 million rows which has 8 columns.We decided to partition the table.Most of the queries in our environment uses 4 columns in the where clause or joins.If I partition the table with 4 columns then I may get better performance.Can we partition the table on multiple columns(like partitioning on id,deptid,designation)?函数
Thanks,sqlserver
答:spa
noorm
You can partition by creating a persisted computed columns.server
意思就是,目前SQL Server还不支持将多个列做为分区函数的分区依据,只能用一列做为分区函数的分区依据,可是咱们能够将多个列构造为一个计算列(computed columns)来做为分区依据。ci
参考文献:get