How to get a list of unique keys

I was wondering how to get a list of all the unique keys inside a columnstore table. Show Indexes does give a list of all the indexes but the unique keys are mentioned as “BTREE” which does not really guarantee it being a unique key. Also, the where clause seems to throw an error when used with Show Indexes. Is there some way to get unique key information from information_schema?


The information_schema.statistics table includes all indexes including unique keys. In columnstore tables unenforced unique keys have index_type shown as BTREE (it’s not actually btree, because it is logical-only and isn’t stored at all, this is a display issue that will be corrected in the future).