I am using COPY public.source TO STDOUT;
It is copying table source from database foo and sending it to psql shell
.
1 1 1
2 2 2
3 0 3
4 1 4
5 2 0
6 0 1
7 1 2
8 2 3
9 0 4
10 1 0
I want to copy all records from the same table source
of database foo
to table dest in database bar. Any idea how can I do it with query like COPY public.source TO <missing solution to copy data into bar.public.dest>;