Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 2 of 2 total
Thread Renaming a column should rename all references of the column
Tue, Dec 10 2013 4:53 PMPermanent Link

Barry

I have several views that reference the same table and these views use column names.

I can use EDBMgr to rename a column of the table, but when it is finished and I click anywhere on the tree, it gives me an error:

"ElevateDB Errror #700  An error was found in the view "MyView" ... the column OldColumn does not exist in MyTable".

It keeps doing this until I fix the problem. This can be a PIA.

The proper way to rename a column is to find all references to "OldColumnName" and if found in a view, edit these views and comment out the column list and replace it with a "*". I also have to comment out all triggers that reference the old name. I then rename the column in the table and go through and uncomment the views and rename the old column name to the new column name. And the same with the triggers. The procedures and functions also have to be changed.

Why can't EDBMgr automatically rename all references of the old column name? (In Views, Stored Procedures Triggers etc.)

It would make things so much easier. Smile

Barry
Tue, Dec 17 2013 9:42 AMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Barry,

<< I have several views that reference the same table and these views use
column names.

I can use EDBMgr to rename a column of the table, but when it is finished
and I click anywhere on the tree, it gives me an error:

"ElevateDB Errror #700  An error was found in the view "MyView" ... the
column OldColumn does not exist in MyTable". >>

I'll see what I can do.   EDB does it now with triggers, so it definitely
has the capability.

Tim Young
Elevate Software
www.elevatesoft.com
Image