Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

COPY duckdb_table FROM STDIN #298

Open
JelteF opened this issue Oct 16, 2024 · 0 comments
Open

COPY duckdb_table FROM STDIN #298

JelteF opened this issue Oct 16, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@JelteF
Copy link
Collaborator

JelteF commented Oct 16, 2024

Right now if you try to copy into a duckdb table (MotherDuck or temporary) you'll get an error. An example of this is the following psql commands (\copy is a psql meta-command that transforms into COPY ... FROM STDIN)

CREATE TEMP TABLE t(a int) USING duckdb;
\copy t FROM 'my_local_data.csv' (FORMAT 'csv', quote '"', header 1, DELIMITER '|');

You then get this error:

ERROR:  0A000: duckdb does not implement duckdb_slot_callbacks

A workaround for this issue is to first do the COPY into a postgres table and then do CREATE TABLE AS.

Related to #30 but different. #30 is about writing the results from a duckdb-only query into a Postgres heap table. While this issue is about writing from Postgres input to a duckdb table.

@JelteF JelteF added the enhancement New feature or request label Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant