Skip to content

Utility for saving Postgres SQL queries results to .xlsx file

License

Notifications You must be signed in to change notification settings

hardened-user/psql2xlsx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Postgres SQL to .xlsx

Utility for saving Postgres SQL queries results to .xlsx file 

Required

  • Python 3.x
    • psycopg2
    • xlsxwriter

Example

Help

user@localhost:~$ ./psql2xlsx.py -h

Config

user@localhost:~$ nano config.ini

Run

user@localhost:~$ ./psql2xlsx.py -o /tmp/1.xlsx
[..] Generated page :: page1 ...
[OK] PostgreSQL successfully connected
[..] Generated page :: page2 ...
[OK] PostgreSQL successfully connected
[..] Generated page :: page3 ...
[OK] PostgreSQL successfully connected
[OK] Workbook saved :: /tmp/1.xlsx

See also WiKi page.

About

Utility for saving Postgres SQL queries results to .xlsx file

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages