Hi,
I was wondering whether there is a simple method of updating an storage entity rather than updating the whole model from the db. Basically I have added 2 columns to a View(in the DB) and the easiest approach I have at present is to add the 2 columns manually to the View Object in ED. I wish there was some form of right click "sync this Table/View from DB". I do find the "Update Model from Database" to be a little dangerous. I can select just the one View of interest, in "Recreate Model", and then all the other entities disappear because I have not selected them. If I do not "Recreate Model", I see no objects to update.
Thoughts appreciated.
Thanks.
What is the best way to add new columns to a Table/View in the Store Model when the DB changes?
Re: What is the best way to add new columns to a Table/View in the Store Model when the DB changes?
We recommend using Update Model From Database Wizard (do not choose "Recreate Model").EdB wrote:I was wondering whether there is a simple method of updating an storage entity rather than updating the whole model from the db.
We cannot reproduce the issue with the latest (5.5.105) build of Entity Developer. Steps for a simple test:EdB wrote:If I do not "Recreate Model", I see no objects to update.
1. Create a view in your database:
Code: Select all
CREATE OR REPLACE VIEW DEPT_VIEW (
DEPTNO,
DNAME
)
AS
SELECT "DEPTNO","DNAME" FROM dept;
3. Replace original view with the following one:
Code: Select all
CREATE OR REPLACE VIEW DEPT_VIEW (
DEPTNO,
DNAME,
LOC
)
AS
SELECT "DEPTNO","DNAME","LOC" FROM dept;
[DEPT_VIEW] Columns were changed.
[LOC] LOC was added.
Please tell us which steps we should follow to reproduce the problem in our environment.