Skip to content
This repository has been archived by the owner on Oct 10, 2022. It is now read-only.

Generator does not run on Views #35

Open
miltonhowe opened this issue Feb 14, 2018 · 5 comments
Open

Generator does not run on Views #35

miltonhowe opened this issue Feb 14, 2018 · 5 comments
Labels
enhancement new feature or bug with easy workaround

Comments

@miltonhowe
Copy link
Contributor

miltonhowe commented Feb 14, 2018

I am using MySQL.

The generator identifies all the tables but it does not see the views.
It would be nice if we could generate models for views.

It seems that it would require the generator working on tables without primary keys. I do not think you can add a primary key to a view at least not in MySql.

--edited--

it looks like typeorm itself does not support views or any table without a primary column:

typeorm/typeorm#1135

@Kononnable
Copy link
Owner

We should wait for typeorm implementation for views and then decide if it can be reverse engineered from db.
Typeorm proposal typeorm/typeorm#1024

@Kononnable Kononnable added enhancement new feature or bug with easy workaround typeorm implementation needed labels Feb 18, 2018
@pjolayres
Copy link

View entities will be released in 0.2.17 typeorm/typeorm#1024 (comment)

@kzimny
Copy link

kzimny commented Jul 1, 2019

@Kononnable : views are implemented in typeorm. Can you include views into model generation?

@queejie
Copy link

queejie commented Oct 8, 2021

Thanks very much for this utility. Is there any update on generating view entities?

@aylusltd
Copy link

Just wanted to resurface this. Would love to help draft a PR for this.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement new feature or bug with easy workaround
Projects
None yet
Development

No branches or pull requests

6 participants