-
-
Notifications
You must be signed in to change notification settings - Fork 492
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
#[sea_orm(indexed)]
only works for MySQL
#554
Comments
I'd opened a similar issue, incorrectly against sea-query, too : SeaQL/sea-query#232 |
Thanks!! @grtlr
As discussed on Discord the first thing I would do was this. |
We should separate the logic from create_table_from_entity and extract to a new function create_index_from_entity |
This was referenced Apr 25, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
Using the
#[sea_orm(indexed)]
property only works for the MySQL backend and crashes when using sqlite.Steps to Reproduce
Put the
#[sea_orm(indexed)]
property on any field of a struct that derivesDeriveEntityModel
while using a sqlite backend.Expected Behavior
Ideally it would create the index, but at least it shouldn't crash, emitting an error at compile time.
Actual Behavior
It crashes.
Reproduces How Often
Everytime 😉.
Versions
I'm running
sea-orm v0.6.0
.Additional Information
It might be helpful to emphasize this in the appropriate sections of the documentation.
The text was updated successfully, but these errors were encountered: