[ hey guys, please trim your replies ] Sergey Koposov <skoposov@xxxxxxx> writes: > On Tue, 2019-07-23 at 16:04 -0700, Adrian Klaver wrote: >> That is only supposed to happen if you use -C(--create) and I am seeing >> that in your examples. > For some reason I see when I just have > a command like this it doesnt' have a grant connect on database > ~/soft/pgsql_install/bin/pg_dump -U skoposov -h localhost -n xx --no-tablespaces test1 > but when I add '-Fc' flag to pg_dump, I can see 'grant connect' inside the output (interdispersed with binary stuff) The GRANT CONNECT will be in the archive, but pg_restore should only print it if you specified -C. Experimenting, however, I see that that only works as intended if I use v11 pg_restore. I can replicate your result if I use v10 pg_restore. So ... don't do that. regards, tom lane