CartoDB / odbc_fdw

PostgreSQL Foreign-data Wrapper for ODBC
Other
66 stars 22 forks source link

Questions: How to select from SQL Server #121

Open mettemusen opened 4 years ago

mettemusen commented 4 years ago

Hi

Being new to Postgres and need to connect to the SQL Server.

Can you come with an example to access SQL Server from Postgres ?

I have installed the FDW but am unsure what to have in the create server options ... create server sqlserver foreign data wrapper odbc_fdw options (

And that goes for the user mapping too...

And do I need to create foreigh table or can I just use IMPORT ?

Lots of questions I know ...

Best regards Mette

mlt commented 3 years ago

This is not stack exchange.. nevertheless, you can find an example in AppVeyor testing. Server options template and actual data to give you an idea. User mapping is there just to auto set up credentials for a given PG role. You can see it in the links I mentioned. And yes, you can just import.

huolijian commented 3 years ago

Hi,

I'm also working on this connection.I have a problem: how to install ODBC_fdw correctly so that "CREATE EXTENSION ODBC_fdw" can work properly.My system is Windows.

Best wish for you! Lijian

mlt commented 3 years ago

What error do you get? How did you try to install it? Usually you move dll into lib/ folder and dot control and dot sql files into share/extension/ .