Issue with Views

  • Hi,

    I'm an oracle DBA newly working on a SqlServer 2005 project.

    If I create a view based on a table, then rename the table, in Oracle Enterprise Manager, the associated view turns red, because the underlying table name it is based on no longer exists.

    This doesn't happen in SS Management Studio, the view definition still references the 'old' tablename. Nothing tells me there may be a potential problem

    Am I missing a trick here?

  • Create a view with Schemabinding and they will not be able to rename the table for the first place.

    Regards,Yelena Varsha

  • Hi

    Be very carefull before using schemabinding.

    Better soultion to this would be give rights for modifying the tables only to the required people. Atleast they will know whether a table has any dependencies.

    You can check the dependencies on a table by right clicking on it and selecting View dependencies.

    "Keep Trying"

  • There are a number of ways to prevent changing the name of a table - as highlighted by the previous posters; however, the answer to your question is that there is no equivalent to the visual display that you alluded to in Oracle.

    Paul

  • Are there any flags to look at in any of the Sys tables to see that a view has become Invalid?

  • dont think so

    "Keep Trying"

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply