Demantra Partitioning and the First PK Column
- by user702295
We have found that it is necessary in Demantra to have an index that matches the partition key, although it does not have to be the PK. It is ok
to create a new index instead of changing the PK.
For example, if my PK on SALES_DATA is (ITEM_ID, LOCATION_ID, SALES_DATE) and I decide partition by SALES_DATE, then I should add an index starting
with the partition key like this: (SALES_DATE, ITEM_ID, LOCATION_ID).
* Note that the first column of the new index matches the partition key.
It might also be helpful to create a 2nd index with the other PK columns reversed (SALES_DATE, LOCATION_ID, ITEM_ID). Again, the first column
matches the partition key.