{"id":13812972,"url":"https://github.com/dimitri/pgcharts","last_synced_at":"2025-07-06T02:33:54.860Z","repository":{"id":19938787,"uuid":"23205414","full_name":"dimitri/pgcharts","owner":"dimitri","description":"Turn your PostgreSQL queries into Charts","archived":false,"fork":false,"pushed_at":"2020-06-01T19:03:33.000Z","size":15317,"stargazers_count":394,"open_issues_count":13,"forks_count":24,"subscribers_count":25,"default_branch":"master","last_synced_at":"2025-01-06T03:23:20.276Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Common Lisp","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"ferd/vmstats","license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dimitri.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-08-21T22:45:05.000Z","updated_at":"2024-12-30T06:30:05.000Z","dependencies_parsed_at":"2022-07-25T07:16:58.988Z","dependency_job_id":null,"html_url":"https://github.com/dimitri/pgcharts","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimitri%2Fpgcharts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimitri%2Fpgcharts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimitri%2Fpgcharts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dimitri%2Fpgcharts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dimitri","download_url":"https://codeload.github.com/dimitri/pgcharts/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240415656,"owners_count":19797670,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-04T04:00:58.909Z","updated_at":"2025-02-24T04:21:52.392Z","avatar_url":"https://github.com/dimitri.png","language":"Common Lisp","readme":"# PostgreSQL Charts\n\n## Screen Shots\n\nIt's intended as a visual project. Here's what it looks like.\n\n### Query editing pane\n\n![pgcharts-query](https://raw.github.com/dimitri/pgcharts/master/propaganda/pgcharts-query.png)\n\n### Chart pane\n\n![pgcharts-bar-chart](https://raw.github.com/dimitri/pgcharts/master/propaganda/pgcharts-bar-chart.png)\n\n### Query listing pane\n\n![pgcharts-query-list](https://raw.github.com/dimitri/pgcharts/master/propaganda/pgcharts-query-list.png)\n\n### Chart only pane\n\nSo that you can give an URL to just the chart for your coworkers to see (and\ndownload as a PDF, PNG, JPEG or SVG document):\n\n![pgcharts-chart](https://raw.github.com/dimitri/pgcharts/master/propaganda/pgcharts-chart.png)\n\n## Description\n\nThe *pgcharts* projects is a little web application that takes as input an\nSQL query text and outputs its data in one of the following forms:\n\n  - HTML table\n  - Column Chart\n  - Bar Chart\n  - Pie Chart\n  - Donut Chart\n  \nWith more to come (TODO):\n\n  - Area Chart\n  - Line Chart\n  - Stacked Area Chart\n  - Stacked Bar Chart\n  - Grouped Bar Chart\n  - CSV file\n\n# Initial Setup\n\nThe *pgcharts* application needs its own PostgreSQL database to be able to\nregister user queries and their charts setup:\n\n    $ createdb pgcharts\n    $ pgcharts setup pgsql://localhost/pgcharts\n    \nThen you can start the service, which defaults to listening to\n[http://localhost:9042/]():\n\n    $ pgcharts start\n    $ open http://localhost:9042/\n\nNow, you can use *pgcharts* from your browser. Issue new query, save them\naway, and see nice charts from their results!\n\n# Registering databases\n\nOnce the *pgcharts* database has been created, it's necessary to\n***register*** the database servers you want to run queries against:\n    \n    $ pgcharts register pgsql://user:pass@host/dbname\n    $ pgcharts register pgsql://user:pass@host/seconddbname?sslmode=require\n    \nThe *sslmode* option accepts the following values: `disable`, `allow`,\n`prefer` and `require`. The `allow` and `prefer` options are implements in\nthe same way, translating to the\n[Postmodern](https://marijnhaverbeke.nl/postmodern/postmodern.html)\nPostgreSQL driver's value `:try`, where `:try` means *if the server supports\nit*.\n\n# Implementation\n\npgchart needs a database where to handle its own data, as it is storing a\nlist of database connections (where to run the queries) and a list of\nqueries (with a name and a tags list).\n\nTODO: see about storing query results on the *pgcharts* database so that\n      it's possible to get back to them later. Maybe with some ways to run\n      the query again and compare?\n\n# Security\n\nThe *pgcharts* web service offers no security implementation, no user role\nmanagement or privileges. To keep the service secure, users are only allowed\nto query against *registered* database servers.\n\nTo register a database server to *pgcharts*, the command line interface must\nbe used, so only the service administrator is in a position to register new\ndatabase servers.\n\n# Usage\n\npgcharts is a self-contained web application. As such, when you start the\ncommand line application, it starts its own web server that you can connect\nto.\n\n# Install\n\nThe *pgcharts* application has been written in Common Lisp and uses a bunch\nof librairies that are available through the *Quicklisp* distribution\nsystem. The included `Makefile` cares about building a self-contained binary\nfor you, and can be used as following:\n\n    $ \u003cinstall recent sbcl\u003e\n    $ make\n    $ ./build/bin/pgcharts --help\n\nNote that the self-contained binary also includes static web resources such\nas *jquery*, *bootstrap*, *Highcharts* and *codemirror*.\n\n## Build Dependencies\n\nYou need a recent enough [SBCL](http://sbcl.org/) Common Lisp compiler to be\nable to compile pgcharts. It's easy to install on Linux, MacOSX and Windows.\n\n    debian$ sudo apt-get install sbcl\n    centos$ sudo yum install sbcl\n    macosx$ brew install sbcl\n","funding_links":[],"categories":["Applications","Virtual or Unsure of Location","Common Lisp"],"sub_categories":["Development Tools","Philippines"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdimitri%2Fpgcharts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdimitri%2Fpgcharts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdimitri%2Fpgcharts/lists"}