54 elog(
ERROR,
"cache lookup failed for operator class %u", opclassoid);
57 opfamilyoid = classform->opcfamily;
58 opcintype = classform->opcintype;
59 opckeytype = classform->opckeytype;
61 opckeytype = opcintype;
62 opclassname =
NameStr(classform->opcname);
67 elog(
ERROR,
"cache lookup failed for operator family %u", opfamilyoid);
70 opfamilyname =
NameStr(familyform->opfname);
87 if (procform->amproclefttype != procform->amprocrighttype)
90 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
91 errmsg(
"bloom opfamily %s contains support procedure %s with cross-type registration",
101 if (procform->amproclefttype != opcintype)
105 switch (procform->amprocnum)
113 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
114 errmsg(
"bloom opfamily %s contains function %s with invalid support number %d",
117 procform->amprocnum)));
125 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
126 errmsg(
"gist opfamily %s contains function %s with wrong signature for support number %d",
129 procform->amprocnum)));
141 if (oprform->amopstrategy < 1 ||
145 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
146 errmsg(
"bloom opfamily %s contains operator %s with invalid strategy number %d",
149 oprform->amopstrategy)));
154 if (oprform->amoppurpose != AMOP_SEARCH ||
158 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
159 errmsg(
"bloom opfamily %s contains invalid ORDER BY specification for operator %s",
167 oprform->amoplefttype,
168 oprform->amoprighttype))
171 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
172 errmsg(
"bloom opfamily %s contains operator %s with wrong signature",
182 foreach(lc, grouplist)
187 if (thisgroup->
lefttype == opcintype &&
189 opclassgroup = thisgroup;
205 (opclassgroup->
functionset & (((uint64) 1) << i)) != 0)
208 (
errcode(ERRCODE_INVALID_OBJECT_DEFINITION),
209 errmsg(
"bloom opclass %s is missing support function %d",
FormData_pg_amproc * Form_pg_amproc
int errcode(int sqlerrcode)
char * format_operator(Oid operator_oid)
#define OidIsValid(objectId)
void ReleaseCatCacheList(CatCList *list)
CatCTup * members[FLEXIBLE_ARRAY_MEMBER]
bool check_amproc_signature(Oid funcid, Oid restype, bool exact, int minargs, int maxargs,...)
#define ObjectIdGetDatum(X)
List * identify_opfamily_groups(CatCList *oprlist, CatCList *proclist)
#define SearchSysCacheList1(cacheId, key1)
#define ereport(elevel, rest)
#define BLOOM_NSTRATEGIES
HeapTuple SearchSysCache1(int cacheId, Datum key1)
FormData_pg_opfamily * Form_pg_opfamily
void ReleaseSysCache(HeapTuple tuple)
char * format_procedure(Oid procedure_oid)
#define HeapTupleIsValid(tuple)
bool check_amop_signature(Oid opno, Oid restype, Oid lefttype, Oid righttype)
int errmsg(const char *fmt,...)
FormData_pg_amop * Form_pg_amop
FormData_pg_opclass * Form_pg_opclass