"Alastair Bell" Turner "" <bell(at)tangent(dot)co(dot)za> writes:
> I'm trying to build a c trigger with the Server Programming Interface and
> not having a lot of joy.
I think what you need to return from a trigger is PointerGetDatum() of a
HeapTuple. TupleGetDatum is a different animal that is *not* used for
trigger results, for mostly-historical reasons.
There are several working examples in the contrib/ modules.
regards, tom lane