The remote query that is generated in the query plan is:SELECTRemote1001."userid" Col1002, Remote1001."firstname" Col1003, Remote1001."LastName" Col1004 FROM "ChangeManage"."dbo"."TeamMembers" Remote1001
The remote table is scripted as follows:CREATE TABLE [dbo].[TeamMembers] ( [UserID] [varchar] (25) NOT NULL , [FirstName] [varchar] (50) NULL , [LastName] [varchar] (50) NULL )ALTER TABLE [dbo].[TeamMembers] WITH NOCHECK ADD CONSTRAINT [PK_TeamMembers] PRIMARY KEY NONCLUSTERED ([UserID]) WITH FILLFACTOR = 90
There is no difference in the remote query that is generated in the query plan when I name all the columns.May I also mention that there are no tables shown in the following list in Enterprise Manager tree structure:<LocalServerName> | Security | Linked Servers | DOITRPT1 | Tables.The reason for this, according to the profiler and my limited debug skills, is that the procedure exec master..sp_tables_ex N'DOITRPT1' , null, null, null, '''TABLE'''
returns no records. This is because there are no records of type 'TABLE' registered. But I don't know why.--SMerrillSeattle, WA