[dbo].[sysusers] column issue

  • HI

    In SQL server 2000 the sysuser table had an suid column. in Sql server 2008 that table changed to a sys view and the column name changed to the uid. the program that I am using is old and its refering to that column. is there anyway to alter those system view to map another column?

    thanks

  • No, you can't change the definition of the system views.

    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
  • No. But maybe you could create your own view with a similar name -- such as dbo.sysusers2 -- and change your code to use the view name?

    create view dbo.sysusers2

    as

    select uid as suid, status, name, sid, roles, createdate, updatedate, altuid, password, gid,

    environ, hasdbaccess, islogin, isntname, isntgroup, isntuser, issqluser, isaliased, issqlrole, isapprole

    from dbo.sysusers

    SQL DBA,SQL Server MVP(07, 08, 09) A socialist is someone who will give you the shirt off *someone else's* back.

  • The problem is that I dont have a way if changing the source code. this is an old ERP system (PSI) that its was based on SQL server 7. now that I am trying to upgrade the database to 2008 its complaining as its referring to the old column name...

  • vblllove (9/23/2016)


    The problem is that I dont have a way if changing the source code. this is an old ERP system (PSI) that its was based on SQL server 7. now that I am trying to upgrade the database to 2008 its complaining as its referring to the old column name...

    I guess your options are upgrade everything or nothing.

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2

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

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