-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
DDC-3603: Readonly columns #4427
Comments
Issued a PR for exactly this: #5728 |
Described my thoughts about this feature in #5728 |
as #5728 has been closed, should this be closed too? if you write your query in dbal, you can completely hide columns from ORM with a schema listener. the column won't be mapped on the entity however, and is not available for DQL / ORM query builder. |
This should not be closed because, as far as I can tell, there still isn't support for read-only generated columns within the ORM. |
Readonly on primary keys is not working for me. As soon as I try to hydrate the object, the UnitOfWork tries to call |
@garak The ticket you are commenting on has nothing to with the PHP language feature |
This was implemented in 2.11 as virtual and generated columns |
Jira issue originally created by user sparrowek:
Sometimes I have a column that is calculated (or have a default value) at the database side. When inserting a new record doctrine issues NULL into such a column that causes problems on some DBMS. I would like to annotate such columns as readonly so that doctrine would skip them in INSERT and UPDATE clauses but still fetch them in SELECT clauses.
The text was updated successfully, but these errors were encountered: