Open paupino opened 4 years ago
e.g.
{NULLTEST :arg {VAR :varno 1 :varattno 3 :vartype 25 :vartypmod -1 :varcollid 100 :varlevelsup 0 :varnoold 1 :varoattno 3 :location 64} :nulltesttype 1 :argisrow false :location 74}
From what I know about this predicate (WHERE last_name IS NOT NULL
in this case), the above structure seems to correlate to the following bison/C code:
| a_expr IS NULL_P %prec IS
{
NullTest *n = makeNode(NullTest);
n->arg = (Expr *) $1;
n->nulltesttype = IS_NULL;
n->location = @2;
$$ = (Node *)n;
}
This relies on unpacking the
pg_node_tree
field onpg_index.indpred
. This looks like a readable serialization format, however is not JSON etc. I suspect that it maps directly to it's C representation.