Home Forums Programming General How to create a view based on a linked server/instance RE: How to create a view based on a linked server/instance

  • Thanks, AJ.

    Here is what I've done and got:

    exec sp_addlinkedserver [GN5DB1\SQL2000], N'SQL Server'

    (1 row(s) affected)

    (1 row(s) affected)

    exec sp_addlinkedsrvlogin [GN5DB1\SQL2000],FALSE,'sa','sa','service'

    (0 row(s) affected)

    (0 row(s) affected)

    (0 row(s) affected)

    (1 row(s) affected)

    create view dbo.ccsystemcontrol as select * from [GN5DB1\SQL2000].cms.dbo.ccsystemcontrol

    Server: Msg 18452, Level 14, State 1, Procedure ccsystemcontrol, Line 11

    Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection.

    I do see, at the end of step 2, a linked server called GN5DB1\SQL2000. But the result of step 3 still puzzles me.

    Any ideas?