you are misunderstanding me ... I should also mention that this is not my design (I am of the viewpoint that this sort of logic should not be in the database at all but happenning at the domain layer)
in development lets say there are two db servers
devdb1 and devdb2
devdb1 in sprocs is accessing devdb2 through a linked server.
in production there are two servers
proddb1 and proddb2
proddb1 in sprocs is asccessing proddb2 through a linked server
the problem is in synchronizing prod and dev ... since they have server names in the sprocs these server names need to be changed during the synchronization process. I am trying to come up with a way of working around this limitation in the interum while a more permanent solution (not using the link servers is under way). My initial thought is that since the server name seems to be the only alias available, one could use DNS to make proddb2 and devdb2 have a DNS alias db2 which points to the correct server dependent upon environment (i.e. in dev db1 points to devdb1 and in production db1 points to proddb1) it would atleast provide the use of the same names for the linked servers between the two environments.
What I am wonderring is if there is a better way of doing this, i.e. can I alias a link server's name in SQL itself as doing it through DNS is a bit kludgey.
Greg
Main Topics
Browse All Topics





by: acperkinsPosted on 2006-01-20 at 10:58:29ID: 15751638
And the big question is why are you accessing Development from Production and vice versa? These environments should not be doing any "cross-polinating" but rather kept totally separate. Linked servers should only be used for ad-hoc queries.