Update 'Copy data to postgresql'

Guillem Borrell Nogueras 2023-01-17 18:15:31 +01:00
parent bc6848771d
commit 9d2fae05ef

@ -44,3 +44,9 @@ You may also need to alter some columns
``` ```
psql -U postgres -h localhost -c 'ALTER TABLE "opportunities" ALTER COLUMN "ProductName" type varchar(1024);' psql -U postgres -h localhost -c 'ALTER TABLE "opportunities" ALTER COLUMN "ProductName" type varchar(1024);'
``` ```
`dr` can also be used to get and process data from postgres
```
psql -U postgres -h localhost -c 'copy (select * from opportunities limit 10) to stdout (FORMAT 'csv', HEADER)' | dr csv -i -a
```