JetBrains / Exposed

Kotlin SQL Framework
http://jetbrains.github.io/Exposed/
Apache License 2.0
8.27k stars 690 forks source link

feat: Add support for variable-length binary columns in H2 #2100

Closed rnett closed 4 months ago

rnett commented 4 months ago

H2 supports VARBINARY columns without a specified length: https://www.h2database.com/html/datatypes.html#binary_varying_type

Currently, the H2 column types throw an error if the length is not specified. We can use VARBINARY without a specified length instead.

While these columns are limited to 1,000,000,000 bytes, in practice I do not think users will run into this limitation. I added a note to the binary column docs anyways.

rnett commented 4 months ago

Went back and forth on whether this should be a fix or a feat - let me know if I should change it.

joc-a commented 4 months ago

Went back and forth on whether this should be a fix or a feat - let me know if I should change it.

I would use fix!, with the exclamation mark signifying that it's a breaking change.

joc-a commented 4 months ago

Went back and forth on whether this should be a fix or a feat - let me know if I should change it.

I would use fix!, with the exclamation mark signifying that it's a breaking change.

Actually, after taking a closer look, I think feat is more appropriate because it was not available for H2 to begin with.