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

Create database views in Migrations using SQL generated from a LINQ projection #465

Closed
ilmax opened this issue Jul 29, 2014 · 5 comments
Closed
Labels
closed-out-of-scope This is not something that will be fixed/implemented and the issue is closed. customer-reported

Comments

@ilmax
Copy link
Contributor

ilmax commented Jul 29, 2014

Note: This issue is tracking a specific aspect of using EF Core with database views. See #827 for an overview of the areas where EF Core interacts with database views. The completion of this feature does not mean that every aspect of database view support has been implemented.


Hi,
I'm wondering if is possible to create view from migrations in a C# fashion. Since a view is essentially a projection of one or more tables, it could be easily created by parsing a C# linq projection, so we can write once and execute everywhere (no more db dependent sql script).

Since all the pieces of this functionality are already there, I think it should be at least possible to do this.

Let me know what you think about it.
Cheers Max

@irium
Copy link

irium commented Aug 1, 2014

Cool idea! Can't wait to see it :)

@rowanmiller
Copy link
Contributor

rowanmiller commented Aug 4, 2014

We agree it could be good to have a first class API for this. It could be similar to the stored procedure API where we specify the high level shape in code and then the body in string/SQL.

Given this isn't currently supported in EF6 and isn't a super common scenario we aren't going to work on it for the initial RTM of EF Core. Moving to backlog.

@skynode
Copy link

skynode commented Sep 18, 2017

Has this left the backlog? Can we expect to have this feature in EF Core 2.1? Thank you!

@ajcvickers
Copy link
Member

This issue is in the Backlog milestone. This means that it is not going to happen for the 2.1 release. We will re-assess the backlog following the 2.1 release and consider this item at that time. However, keep in mind that there are many other high priority features with which it will be competing for resources.

@ajcvickers
Copy link
Member

Note from triage: when considering the value of this against the amount of work to implement, and when comparing to other features on the backlog, generating views from LINQ queries is not something we plan to add to EF Core.

@ajcvickers ajcvickers removed this from the Backlog milestone Oct 27, 2021
@ajcvickers ajcvickers added closed-out-of-scope This is not something that will be fixed/implemented and the issue is closed. and removed type-enhancement area-migrations labels Oct 27, 2021
@ajcvickers ajcvickers reopened this Oct 16, 2022
@ajcvickers ajcvickers closed this as not planned Won't fix, can't repro, duplicate, stale Oct 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-out-of-scope This is not something that will be fixed/implemented and the issue is closed. customer-reported
Projects
None yet
Development

No branches or pull requests

6 participants