CREATE FUNCTION plus(a integer, b integer) RETURNS integer AS $$
BEGIN
RETURN a + b;
END;
$$ LANGUAGE plpgsql;
-- name: MakeIntervalPositional :one
SELECT plus($1, $2::INTEGER);
yields the params struct
type MakeIntervalPositionalParams struct {
A int32
B int32
Column3 int32
}
With an extra field Column3.
The extra field disappears if the INTEGER cast is removed.
yields the params struct
With an extra field
Column3.The extra field disappears if the INTEGER cast is removed.