Wednesday, March 28, 2012

Linked server problem

SELECT
A.PATIENTID
FROM
xxxx.yyyyy.dbo.Patient A
SELECT
*
FROM
xxxx.yyyyy.dbo.Patient A
The first sql does not work and the second one works over linked server.
Does anybody know??Do you get an error? What is it?|||Server: Msg 207, Level 16, State 3, Line 1
Invalid column name 'patientid'.|||Check the spelling of the column name when selecting all columns.|||works fine for me....

select * from server.database.owner.table A
will work OK

select A.column_name from server.database.owner.table A
wiill work OK too....

Spelling most likely problem...

No comments:

Post a Comment