Check max # of col in an hypothetical index

This commit is contained in:
Julien Rouhaud 2015-09-12 15:16:25 +02:00
parent 1aa0463992
commit cceed24e1f

View file

@ -494,6 +494,10 @@ hypo_entry_store_parsetree(IndexStmt *node, const char *queryString)
ncolumns = list_length(node->indexParams);
if (ncolumns > INDEX_MAX_KEYS)
elog(ERROR, "hypopg: cannot use more thant %d columns in an index",
INDEX_MAX_KEYS);
initStringInfo(&indexRelationName);
appendStringInfo(&indexRelationName, "%s", node->accessMethod);
appendStringInfo(&indexRelationName, "_");