Skip to content

Commit 884bf00

Browse files
committed
Prefix vector impl table has its own settings (#18132)
1 parent c4994f1 commit 884bf00

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

src/api/protos/ydb_table.proto

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ message GlobalUniqueIndex {
109109
message GlobalVectorKMeansTreeIndex {
110110
GlobalIndexSettings level_table_settings = 1;
111111
GlobalIndexSettings posting_table_settings = 2;
112+
GlobalIndexSettings prefix_table_settings = 4;
112113
KMeansTreeSettings vector_settings = 3;
113114
}
114115

src/client/table/table.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2531,6 +2531,10 @@ TIndexDescription TIndexDescription::FromProto(const TProto& proto) {
25312531
const auto &vectorProto = proto.global_vector_kmeans_tree_index();
25322532
globalIndexSettings.emplace_back(TGlobalIndexSettings::FromProto(vectorProto.level_table_settings()));
25332533
globalIndexSettings.emplace_back(TGlobalIndexSettings::FromProto(vectorProto.posting_table_settings()));
2534+
const bool prefixVectorIndex = indexColumns.size() > 1;
2535+
if (prefixVectorIndex) {
2536+
globalIndexSettings.emplace_back(TGlobalIndexSettings::FromProto(vectorProto.prefix_table_settings()));
2537+
}
25342538
specializedIndexSettings = TKMeansTreeSettings::FromProto(vectorProto.vector_settings());
25352539
break;
25362540
}

0 commit comments

Comments
 (0)