Hello, I have 2 PostgreSQL databases that [I thought] were identical. Today I noticed that the query "select * from pg_user;" results in different results from each database. My question is what is the easiest/best/safest way to copy the pg_user file from db to another? Can I simply copy the pg_user file from one db to the other and restart the db, or should I use pg_dump on pg_user and import like that? Any and all suggestions are greatly appreciated! TIA -Jim
James Hall <James.Hall@RadioShack.com> writes:
> My question is what is the easiest/best/safest way to copy the pg_user file
> from db to another?
pg_user is a view. You can copy pg_shadow if you are so inclined.
See the pg_dumpall script, which does exactly that before dumping
the database(s) proper.
regards, tom lane
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера