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

Mysql compatibility fixes #259

Merged
merged 1 commit into from
Oct 22, 2021
Merged

Conversation

maebeam
Copy link
Contributor

@maebeam maebeam commented Oct 21, 2021

MySQL uses On("DUPLICATE KEY UPDATE") vs PostgreSQL's On("CONFLICT DO UPDATE") and also has a slightly different format for VALUES.

I also included an example of a change I needed to make to support binary data in MySQL. I understand this change cannot be merged as-is and I would appreciate some guidance on how to make it correctly.

@vmihailenco
Copy link
Member

👍 Thanks for the PR. I am going to merge this as is and work in a separate PR on customizing type handling in dialects.

I also included an example of a change I needed to make to support binary data in MySQL. I understand this change cannot be merged as-is and I would appreciate some guidance on how to make it correctly.

A simple but somewhat messy way is to move AppendBytes to respective dialect packages and change 2 functions to that are responsible for appending data:

I don't like it and going to try to find a better way.

@maebeam
Copy link
Contributor Author

maebeam commented Oct 22, 2021

Wow, thanks for the speedy merge and follow up @vmihailenco!

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

Successfully merging this pull request may close these issues.

2 participants