-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Parameter for collection of enum values contains ints even when correlated column has strings #30921
Comments
I looked into it, and the type mapping is correctly inferred from e.Terrain and applied to the parameter collection. However, we currently just hand the collection to JsonSerializer within CollectionToJsonStringConverter - we currently effectively ignore the element type mapping when writing the parameter. When JSON serialization/deserialization is properly implemented (#30677), we'll build up the parameter JSON string with that, at which point everything should be fine. We can keep this open to remember to test this specific scenario, or just close it as a dup. |
Just want to raise a concern as early as possible here - this bug changes the output of .Contains queries we wrote as early as EF Core 5. This prevents us from using 8 until fixed but we're at least aware of the bug - if this goes out as-is in GA many users could upgrade and be unaware #30677 is currently tagged "type-enhancement" and "needs-design". We're already at preview 4 so I'm nervous that this is a prerequisite - especially if this is closed as a dup Thanks! |
@be-marks we absolutely intend to get this working before 8.0 GA. |
@be-marks also, just to make sure that you're aware: you can configure the SQL compatibility level to an old level (as per the blog post) to make EF switch back to the older SQL. This should allow you to continue using previews even before we fix this (the compatibility level doesn't currently affect anything else). |
Verified fixed:
|
Parameter value below should be
["River", "Beach", "Park"]
:The text was updated successfully, but these errors were encountered: