cancel
Showing results for 
Search instead for 
Did you mean: 

connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

SOLVED
Level 3 Adventurer

connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

Hi Folks,

 

        we want to get the database table data into excel(eg.from linux is in postgres 9.6 excel in windows 10)

1.Client ask to get the table data from readble format.

2.The application of .NET we need to use(Exactly i dont know,i think so)

3.Mainly refrech activity from windows to linux linux-windows through excel..

 

NOTE:-

FYI

        Only get data thorugh ms-excel..

 

Can you help anyoen have the proper steps HOW TO DO..

Do need full 

 

Thanks&Regards

Diny

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
EDB Team Member

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

Hello, 

 

Hope you are doing good. I kindly request you to please follow below steps for your requirement. 

 

1. Install "psqlodbc" driver(select your database version from list) from https://www.postgresql.org/ftp/odbc/versions/msi/

2. Install with "Run as Administrator" privilages. This will install odbc driver for postgresql database. 

3. Go to excel(if MS office 2010)

---> Data tab

---> From Other sources under "get external data sub menu"

---> Select "From Microsoft Query"

---> Under databases, select New data source, Click Ok

---> Give connection name ex:pgcon

---> Select "PostgreSQL Unicode" in drop down list under "select a driver for the type of database you want to access"

---> Click connect

---> Give all Database connection details. Click Ok. 

---> If it is success , it doesn't show any popup. If it is failed, Make sure to disable firewall on linux and add pg_hba entry in DB server and DB should up and run.

---> Intially, Select a default table you want to get data into excel from PG.

---> Later you can write what ever query you want in connection properties. 

 

I considered Excel version is 2010 here, But
Almost all above steps will be same as all MS office versions 

I have attached screen shots for your reference. Hope those will help. Please let me know if you need any more help.

 

Regards

Siva.

 

 

EDB Team Member

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

dsn_method.pngDSN Connection Method(alternate)  Please check images. 

query.pngCustom query setupdata.pngData populateconn_info.pngCreate connectionafter_success.pngConnection setup

6 REPLIES 6
Highlighted
EDB Team Member

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

Hello, 

 

I am looking into your request. 

 

Regards

Siva.

Level 3 Adventurer

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

thanks for your prompt replay..iam waiting

 

Regards

Diny

Gold Adventurer

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

hi @Din2pg do you need read data in PostgreSQL from excel file?

for intance,  load in table or access without load ?

always read-only?

 

regards

EDB Team Member

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

Hello, 

 

Hope you are doing good. I kindly request you to please follow below steps for your requirement. 

 

1. Install "psqlodbc" driver(select your database version from list) from https://www.postgresql.org/ftp/odbc/versions/msi/

2. Install with "Run as Administrator" privilages. This will install odbc driver for postgresql database. 

3. Go to excel(if MS office 2010)

---> Data tab

---> From Other sources under "get external data sub menu"

---> Select "From Microsoft Query"

---> Under databases, select New data source, Click Ok

---> Give connection name ex:pgcon

---> Select "PostgreSQL Unicode" in drop down list under "select a driver for the type of database you want to access"

---> Click connect

---> Give all Database connection details. Click Ok. 

---> If it is success , it doesn't show any popup. If it is failed, Make sure to disable firewall on linux and add pg_hba entry in DB server and DB should up and run.

---> Intially, Select a default table you want to get data into excel from PG.

---> Later you can write what ever query you want in connection properties. 

 

I considered Excel version is 2010 here, But
Almost all above steps will be same as all MS office versions 

I have attached screen shots for your reference. Hope those will help. Please let me know if you need any more help.

 

Regards

Siva.

 

 

EDB Team Member

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

dsn_method.pngDSN Connection Method(alternate)  Please check images. 

query.pngCustom query setupdata.pngData populateconn_info.pngCreate connectionafter_success.pngConnection setup

Level 3 Adventurer

Re: connect Microsoft Excel to PostgreSQL, load data from PostgreSQL to Excel, Refresh Activities

Hi @sivamekala 

 

                             i have been deployed in production..it is working fine.thanks siva your valuble support..

 

@asotolongo  thnak man

 

Regards

Diny.