Page 1 of 1

PostgreSQL to Excel

PostPosted: Mon Oct 25, 2010 9:00 pm
by doco
My work involves writing endless SQL's seemingly and quite often I need the results in Excel. I do not like MSQuery and some of the other canned tools Excel provides to retrieve external data - just too many steps. So, I created my own.

There are many capabilities in Excel such as Pivot Tables, AutoFilter, SubTotal, etc. that are handy for data manipulation on a large scale that would be maybe impracticable for PT3. Below are some screen shots of the Addin.

If you think this is something you might find useful, I will post it in the repository.

Image

Image

The form lays on top of the spreadsheet in a non modal state. You can retrieve SQL from saved text files or type in sql on the fly. The addin will add a menu item [ Poker Tools | Run Postgres SQL... ] to instance the form.

This is simple, that's why I like it and there are not a myriad of wizards, windows and or wysywig to deal with. It has been a great help for me to analyze data in ways not yet available in PT.

Re: PostgreSQL to Excel

PostPosted: Tue Oct 26, 2010 9:29 am
by kraada
That sounds really neat. How large is the file you would need to upload when zipped up? We don't have a ready made repository section for this sort of thing, but if the file is not too large, I could attach it to this thread for you.

Re: PostgreSQL to Excel

PostPosted: Tue Oct 26, 2010 8:14 pm
by doco
The xla is 73KB; zipped its 28KB

Re: PostgreSQL to Excel

PostPosted: Wed Oct 27, 2010 9:01 am
by kraada
Shoot me a PM with your e-mail address and I'll tell you where to send it so that we can get it up here.

Re: PostgreSQL to Excel

PostPosted: Thu Oct 28, 2010 4:03 pm
by zubs1aa
I want this!!!!!!!!!! :) :)

I'd tried something similar to do reporting that I wanted that PT didn't have, but I couldn't get it to work the second time I tried it (the db's wouldn't connect...)

OP- also, at some point I couldn't do what I wanted in excel and ended up with an access DB IIRC. WOuld your tool let access connect?

or, for Kraada etal.... anyone with knowledge on taking access or excel and connecting to the db? I've gotten it to work on occasion, but not others...

Re: PostgreSQL to Excel

PostPosted: Thu Oct 28, 2010 7:04 pm
by doco
If you downloaded the ODBC drivers when you installed PostgreSQL, you should be able to create an Access Project and connect to your PT3 database then create forms, queries, reports from there. Be advised though that any queries you create and save will be stored in the Back End PostgreSQL db - not the Access Project.

As far as the Excel Addin is concerned, currently it will just access PostgreSQL But with simple modification it could access any Back End data source including Excel and or text files. It is the way it is for two reasons 1. Upload size 2. Not sure how it would be received if at all, by other users here. It could grow in flexibility with interest.

Re: PostgreSQL to Excel

PostPosted: Thu Oct 28, 2010 11:58 pm
by zubs1aa
doco wrote:If you downloaded the ODBC drivers when you installed PostgreSQL, you should be able to create an Access Project and connect to your PT3 database then create forms, queries, reports from there. Be advised though that any queries you create and save will be stored in the Back End PostgreSQL db - not the Access Project.

As far as the Excel Addin is concerned, currently it will just access PostgreSQL But with simple modification it could access any Back End data source including Excel and or text files. It is the way it is for two reasons 1. Upload size 2. Not sure how it would be received if at all, by other users here. It could grow in flexibility with interest.


thanks-
I'd start with just getting to excel and be happy.... :)

Re: PostgreSQL to Excel

PostPosted: Fri Nov 05, 2010 12:49 pm
by doco
zubs - Check your PM

Re: PostgreSQL to Excel

PostPosted: Fri Nov 05, 2010 1:15 pm
by kraada
Sorry for the delay guys. Zipped file attached.

highfalutin