CopyOut ​Copy​Out

yaml
type: "io.kestra.plugin.jdbc.postgresql.copyout"
yaml
id: postgres_copy_out
namespace: company.team

tasks:
  - id: copy_out
    type: io.kestra.plugin.jdbc.postgresql.CopyOut
    url: jdbc:postgresql://sample_postgres:5432/world
    username: "{{ secret("POSTGRES_USERNAME") }}"
    password: "{{ secret("POSTGRES_PASSWORD") }}"
    format: CSV
    sql: SELECT 1 AS int, 't'::bool AS bool UNION SELECT 2 AS int, 'f'::bool AS bool
    header: true
    delimiter: "\t"

yaml
id: export_from_postgres
namespace: company.team

tasks:
  - id: export
    type: io.kestra.plugin.jdbc.postgresql.CopyOut
    url: jdbc:postgresql://sample_postgres:5432/world
    username: "{{ secret("POSTGRES_USERNAME") }}"
    password: "{{ secret("POSTGRES_PASSWORD") }}"
    format: CSV
    header: true
    sql: SELECT * FROM country LIMIT 10
    delimiter: ","

  - id: log
    type: io.kestra.plugin.core.log.Log
    message: "{{ outputs.export.rowCount }}"
Properties
SubType string
SubType string
SubType string
SubType string
Default TEXT
Possible Values
TEXTCSVBINARY
Default false
Possible Values
DISABLEALLOWPREFERREQUIREVERIFY_CAVERIFY_FULL
Format uri