> What is a reliable way to programmatically & generically populate an empty schema with all the objects in the public schema as a template?
The simplest way is just to load the attached clone_schema function. It was originally created by Emanuel '3manuek', which I enhanced. It now copies all sequences, tables, indexes, rules, triggers, data(optional), views & functions from any existing schema to a new schema.
Чтобы сделать работу с сайтом удобнее, мы используем cookie и аналитический сервис «Яндекс.Метрика». Продолжая пользоваться сайтом, вы соглашаетесь с их использованием.