"Nick Fankhauser" <nickf(at)ontko(dot)com> writes:
> when I do a \d on pg_stats, it appears that pg_statistic.starelid matches up
> with pg_class.oid, but apparently this is not the case.
It certainly should be the case. starelid matches to pg_class.oid and
staattnum matches to pg_attribute.attnum.
regards, tom lane