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

Error in SQL syntax for UPDATE with certain field types #93

Open
2 tasks done
rynoV opened this issue Oct 29, 2024 · 1 comment
Open
2 tasks done

Error in SQL syntax for UPDATE with certain field types #93

rynoV opened this issue Oct 29, 2024 · 1 comment

Comments

@rynoV
Copy link

rynoV commented Oct 29, 2024

What happens?

When running an update query with a mysql target table, the generated mysql code appears to be invalid:

DuckDB.NET.Data.DuckDBException (0x0000001C): IO Error: Failed to run query "<query>": You have an error
 in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near
 '::<duckdb type>, ...' at line 1

To Reproduce

Have a table in mysql with a binary column and run

update mysql.t set blob_col = '00000000-0000-0000-0000-000000000000'::BLOB;

Same issue comes up when replacing BLOB with DATE and TIMESTAMP WITH TIME ZONE (might be more, those are the ones I've checked)

OS:

Windows 11

MySQL Version:

8.0.35

DuckDB Version:

1.1.1

DuckDB Client:

DuckDB.NET, jdbc, probably doesn't matter

Full Name:

Calum Sieppert

Affiliation:

Auspice Capital

Have you tried this on the latest main branch?

  • I agree

Have you tried the steps to reproduce? Do they include all relevant data and configuration? Does the issue you report still appear there?

  • I agree
@rynoV
Copy link
Author

rynoV commented Oct 29, 2024

The same issue seems to be present for delete statements

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant