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

RDBMS-specific functions in generic Database.Esqueleto module #385

Open
isomorpheme opened this issue Jan 3, 2024 · 3 comments
Open

RDBMS-specific functions in generic Database.Esqueleto module #385

isomorpheme opened this issue Jan 3, 2024 · 3 comments
Milestone

Comments

@isomorpheme
Copy link
Contributor

There's functions like ilike where the docs say:

Supported by PostgreSQL only.

Or others where both MySQL and Postgres support them, but no other RDBMSes. Then there's also modules like Database.Esqueleto.PostgreSQL that have RDBMS-specific code, and this is explicitly pointed out. So it seems like the intent is that such functions don't go in the generic Database.Esqueleto.

It's also pretty confusing as a user, and sometimes frustrating to find a function in HLS autocomplete that I can't actually use. It would be preferable if I can safely use anything from Database.Esqueleto (or of course .Experimental) without having to check individual docs if it's actually available on my RDBMS; anything that's implementation-specific should come from other modules.

@belevy
Copy link
Collaborator

belevy commented Jan 9, 2024

True enough, though removing these functions from Database.Esqueleto is a breaking change.

@belevy belevy added this to the 4.0 milestone Jan 9, 2024
@parsonsmatt
Copy link
Collaborator

I think we can do this in two parts: deprecation for 3.6 and removal in 4.0

@parsonsmatt
Copy link
Collaborator

I looked into this and I think only ilike needs to be deprecated. The other specific ones are either compatible with flags or new versions, or are already slated for deprecation (ie distinctOn #287 ): #412

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

3 participants