Linked server query problem

From: "Anderson, Steven" <steven(dot)anderson(at)dallascityhall(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Cc: "Lawrence, Don" <don(dot)lawrence(at)dallascityhall(dot)com>
Subject: Linked server query problem
Date: 2008-12-01 12:45:05
Message-ID: B113F3DC22A9154EB1F14F048A15F81403D9F4AA@EXCTY05.city.dallastx.cod
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I have SQL Server 2005 that is linked to Postgresql 8.3.1-1

The following query does not work

SELECT id FROM ALERT.novastar.[public].[point]

Error:

OLE DB provider "MSDASQL" for linked server "ALERT" returned message
"ERROR: syntax error at or near ""Col1004"";

Error while executing the query".

Msg 7320, Level 16, State 2, Line 1

Cannot execute the query

"SELECT "Tbl1002"."id" "Col1004" FROM "novastar"."public"."point"
"Tbl1002""

against OLE DB provider "MSDASQL" for linked server "ALERTIII".

This query does work from MS SQL:

EXEC ('SELECT id FROM point') at ALERT

Any ideas as what the problem is

Thank you

Steven Anderson

City of Dallas

Streets Department

Flood Control

2255 Irving Blvd.

Dallas, TX 75207-6201

(214)671-0424

fax - (214)670-6526

web http://fc.dallascityhall.com

wireless web http://fc.dallascityhall.com/wap

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Andrus 2008-12-01 12:55:48 Re: db backup script in gentoo
Previous Message Maxim Boguk 2008-12-01 12:32:14 Indexes on NULL's and order by ... limit N queries