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

Migrations: SQL Server Filtered Indexes #5817

Closed
MarcoLoetscher opened this issue Jun 20, 2016 · 1 comment
Closed

Migrations: SQL Server Filtered Indexes #5817

MarcoLoetscher opened this issue Jun 20, 2016 · 1 comment
Labels
closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. good first issue This issue should be relatively straightforward to fix. help wanted This issue involves technologies where we are not experts. Expert help would be appreciated. type-enhancement
Milestone

Comments

@MarcoLoetscher
Copy link

For indexes on SQL Server, it should be possible to set a filter might as string or lamda expression:
modelBuilder.Entity<Blog>().HasIndex(b => b.Url, "[Url] IS NOT NULL AND [IsActive] = 1");
or
modelBuilder.Entity<Blog>().HasIndex(b => b.Url, b => b.Url != null && b.IsActive == 1);

@rowanmiller rowanmiller added this to the Backlog milestone Jun 20, 2016
@rowanmiller rowanmiller added the help wanted This issue involves technologies where we are not experts. Expert help would be appreciated. label Jun 20, 2016
laskoviymishka added a commit to laskoviymishka/EntityFramework that referenced this issue Oct 26, 2016
laskoviymishka added a commit to laskoviymishka/EntityFramework that referenced this issue Oct 27, 2016
laskoviymishka added a commit to laskoviymishka/EntityFramework that referenced this issue Oct 29, 2016
@AndriySvyryd AndriySvyryd modified the milestones: 1.2.0, Backlog Oct 29, 2016
@AndriySvyryd
Copy link
Member

Fixed in 2e0498a by @laskoviymishka

@AndriySvyryd AndriySvyryd added the closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. label Oct 29, 2016
@bricelam bricelam added the good first issue This issue should be relatively straightforward to fix. label May 31, 2019
@ajcvickers ajcvickers modified the milestones: 2.0.0-preview1, 2.0.0 Oct 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-fixed The issue has been fixed and is/will be included in the release indicated by the issue milestone. good first issue This issue should be relatively straightforward to fix. help wanted This issue involves technologies where we are not experts. Expert help would be appreciated. type-enhancement
Projects
None yet
Development

No branches or pull requests

5 participants