Trying to setup a connection to a PostgresSQL server with MSSQL Polybase. Today we use Linked Server to withdraw data from the Postgresdatabases into MSSQL and it works fine. But there is some functionality with Polybase that would solve some program issus regarding joining etc, and therefore Polybase is the solution. As long it works! ;-)
But I dont get it to work. And I can't find any real help with Google.
This is the code;
> CREATE DATABASE SCOPED CREDENTIAL PG_EXAMPLE WITH IDENTITY = 'pgUSER', Secret = 'verylongpassword';
> CREATE EXTERNAL DATA SOURCE PG_EXAMPLE_DATA
>WITH ( LOCATION = 'odbc://PG_SERVERNAME:5432',
>CONNECTION_OPTIONS = 'Driver={PostgreSQL Unicode(x64)}',
>PUSHDOWN = ON,
>CREDENTIAL = PG_EXAMPLE);
Trying to create a external table:
> CREATE EXTERNAL TABLE databas(
> namn [nvarchar](255) NULL,
> datorid [nvarchar](255) NULL
> ) WITH (
> LOCATION='exampel_databas_on_PGserver',
> DATA_SOURCE=PG_EXAMPLE_DATA
> );
ERROR MESSAGE
> Msg 105082, Level 16, State 1, Line 10
> 105082;Generic ODBC error: Error while executing the query .
Can anybody spread some light here, what I'm doing wrong. Somebody perhaps tried and got it to work??
Any help and suggestion is very mutch appreciated.
Thanks!!!
question from:
https://stackoverflow.com/questions/65904854/cannot-connect-polybase-to-postgresql 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…