Hacker News new | ask | show | jobs
by andrewdunstan 5370 days ago
Neat.

You could avoid having to create a per-schema id function by passing the shard id and the sequence oid as params to the function, so you'd have default public.next_id(5,'insta5.table_id_seq'::regclass)