Naming of colums returned from function have changed

Using PGNP with MS SQL Server, Data Transformation Services (DTS), SQL Server Integration Services (SSIS), Linked Servers, Snapshot and Transactional Replication and more.

Naming of colums returned from function have changed

Postby mc_coder » Wed Dec 12, 2012 12:48 pm

Hi,

I have some code which calls functions in a PostgreSQL DB using SQL linked servers. When called in PostgreSQL the column name is usually the same as the function called and up until I updated to the latest version of PGOLEDB the behaviour was the same. With the latest version I know get a column name like COLUMN1. To test try the folowing:

In PostgreSQL - select version(); - you should see a column called version
In SQL Server using a linked server - select * from OPENQUERY(LINKEDSERVER,'select version()') - you should see a column called COLUMN1

I can fix this by changing the SQL Server query to the following select * from OPENQUERY(LINKEDSERVER,'select version() as version') but I'd rather not have to do that.

Version 1.4.0.3056 was the version I was using that worked as expected. Can anyone shed some light on this?

Regards,

Martin
mc_coder
 
Posts: 7
Joined: Wed Nov 14, 2012 7:37 am

Re: Naming of colums returned from function have changed

Postby Moderator » Tue Dec 18, 2012 9:35 pm

We have fixed the bug and will publish it shortly. It will be available in any build after 3108.

Thank you! Please let us know if you notice any defect.
User avatar
Moderator
Site Admin
 
Posts: 297
Joined: Wed Oct 29, 2008 11:27 pm

Re: Naming of colums returned from function have changed

Postby mc_coder » Wed Dec 19, 2012 1:42 am

Thanks. I'm waiting for suppport to issue me with a fix for the other issue I reported. Will this fix be included in the build?

Regards,

Martin
mc_coder
 
Posts: 7
Joined: Wed Nov 14, 2012 7:37 am

Re: Naming of colums returned from function have changed

Postby Moderator » Wed Dec 26, 2012 8:51 am

We sent "unofficial" build 3110 with the fixes. They will also be published "officially" shortly.
User avatar
Moderator
Site Admin
 
Posts: 297
Joined: Wed Oct 29, 2008 11:27 pm


Return to SQL Server/DTS/SSIS/Linked servers/Replication

Who is online

Users browsing this forum: No registered users and 2 guests

cron