cockroachdb / cockroachdb/cockroach

copy: support json format

Open
#103,543 0 comments 0 reactions 0 assignees View on GitHub
C-enhancement
Dominant language
Go
Stars
32.5k
Forks
4.1k
PR merge metrics
PR metrics pending

Description

**Is your feature request related to a problem? Please describe.**
Testing DuckDB Postgres connector which relies on libpq and which translates queries to COPY (SELECT *) TO STDOUT (FORMAT json);`

```sql
COPY (SELECT * FROM test LIMIT 5) TO STDOUT (FORMAT json);
invalid syntax: statement ignored: at or near "json": syntax error: unimplemented: this syntax
SQLSTATE: 0A000
DETAIL: source SQL:
COPY (SELECT * FROM test LIMIT 5) TO STDOUT (FORMAT json)
^
HINT: You have attempted to use a feature that is not yet implemented.
See: https://go.crdb.dev/issue-v/96590/v23.1
```

**Describe the solution you'd like**
support copy with json

**Describe alternatives you've considered**
unfortunately DuckDB does not support csv or text

This is CockroachDB 23.1.1

Related issues: https://github.com/cockroachdb/cockroach/issues/103542 and https://github.com/cockroachdb/cockroach/issues/103544

Jira issue: CRDB-28070

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.