Changing Table Names

  • Hello good folks of the SQL world. In the database that I have designed I'm having a problem with the naming conventions of the tables. For instance, my first table iscorrect and is:

    dbo.tblRegions

    However, every table after that is laid out in the following way:

    HYDRO\mvasas.tblContacts

    HYDRO\mvasas.tblReleaseDates

    and so on. How can I change these so that they read dbo.tbl_name? I tried doing a simple "Rename" in the format of dbo.tblContacts but that turned into HYDRO\mvasas.dbo.tblContacts which is worse. Any ideas?

    Regards:
    Mordred
    Keep on Coding in the Free World

  • You need to change the schema of the table, which is not simply renaming the table.

    First, have the default schema for your user changed in the user properties. Then, read this http://msdn.microsoft.com/en-us/library/ms173423.aspx

    Jared
    CE - Microsoft

  • Why a tbl prefix anyway? It's obvious it's a table from how it's used.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass
  • GilaMonster (7/19/2012)


    Why a tbl prefix anyway? It's obvious it's a table from how it's used.

    Because that is the naming convention that I have learned.

    Regards:
    Mordred
    Keep on Coding in the Free World

Viewing 4 posts - 1 through 3 (of 3 total)

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