Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ecEj4-0001QM-Rf for pgsql-gui-dev@arkaria.postgresql.org; Thu, 18 Jan 2018 18:15:46 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ecEj4-0006jW-DQ for pgsql-gui-dev@arkaria.postgresql.org; Thu, 18 Jan 2018 18:15:46 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1ecEj4-0006jN-4a for pgsql-gui-dev@lists.postgresql.org; Thu, 18 Jan 2018 18:15:46 +0000 Received: from mail-lf0-x236.google.com ([2a00:1450:4010:c07::236]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1ecEj0-00031d-50 for pgsql-gui-dev@lists.postgresql.org; Thu, 18 Jan 2018 18:15:45 +0000 Received: by mail-lf0-x236.google.com with SMTP id a204so19547738lfa.2 for ; Thu, 18 Jan 2018 10:15:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=dDV6Oz0RhD90mh7sm59vlGKtj9DWuXeBMQx/T7pJINw=; b=k5tYipSSi1IyD8LgsT0FHDj6iVnZB3EKEli3HRIClH3hM8hw4Vt54PyNtrFlrClZa7 Uv7JjnWE2atVqYdIfWgywrDDLSjN7IGl+NLUihry6v2eNX8lSh8+O6Z3zL+x7WwkjsBl d1qrVi2JKXtIjCv22/K7G2Q9erW+J0SuASSl3MsNOQDC4d+UxjxmGzt6DyswBJyVOuFL hN+XlGxJJ/V8QP1l2GfAI+zcDWmYAomCw4LFwcUvEW6V2eGzcUAF5tzLvhKVrg1PBKlx ImhVgVPa1gcTXZmWEYLc8UFSTaCNv1wc/oDIA1Hne0JfB/jrZJ/Gu1DBNhkNzTZ4WPGV yntw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=dDV6Oz0RhD90mh7sm59vlGKtj9DWuXeBMQx/T7pJINw=; b=aPw4icgvoAjipxkFP1WATiyPYG1cKNadWAKJux//ark5wC2dmBaVaDyhQDpaqci8JW sM2yT7oWDF6OVpwVxy6hYCKorGO4UH0xt+lfkLc0sMAFbtzJkt7+Y36GvpnEil40LKob CiMHW0OvjnO9xB2kv7Z+n1HvMijesMjGB8/qB96E9Pz+lB1mcOMN1m1t81VCnvYq3kTa tvwGXTnaKcgA1QBW/o9feZqbsznBoti18eFf/r8Kz13KVn/vz3+RhYjaVbLSFDCLqAwy XiqfhmAaVNwCnnntLXQmXiBSw5X39ydaoa5n5v/gvSOE2eOACDq9HNDHFYe8O35pCcI1 93eA== X-Gm-Message-State: AKwxytfqOtyQSwc+aDGRjHY0IfEVdvpeoPDDBX4zo2jFCnj6yiR4Ir5K jeDZWz/FTijRAuIepfeyaK3OFiG5jcYVkbqjfzLjwsL8 X-Google-Smtp-Source: ACJfBovJQBt1T78InXQQ3aDOr8CaDhNkHfmhhNVC74895aMcipa7c4zKUSYjgdeOAxchpH8QS9yk7M4EBMEDqPNc/18= X-Received: by 10.25.90.81 with SMTP id o78mr14938936lfb.123.1516299340668; Thu, 18 Jan 2018 10:15:40 -0800 (PST) MIME-Version: 1.0 Received: by 10.46.43.153 with HTTP; Thu, 18 Jan 2018 10:15:20 -0800 (PST) From: Amjith Ramanujam Date: Thu, 18 Jan 2018 10:15:20 -0800 Message-ID: Subject: pgcli To: pgsql-gui-dev@lists.postgresql.org Content-Type: multipart/alternative; boundary="94eb2c14aac892e518056310f30e" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --94eb2c14aac892e518056310f30e Content-Type: text/plain; charset="UTF-8" Hi folks, I'm Amjith. I created PGCLI , an Opensource client for Postgres. It is a command line client with GUI features such as Auto-Completion and Syntax Highlighting. My goal for participation is gathering consensus to add support in Postgres to provide support for accessing metadata about a database without complicated queries. For example, in order to get a list of tables in a database I have to run a query like this: ``` SELECT n.nspname schema_name, c.relname table_name FROM pg_catalog.pg_class c LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE c.relkind = ANY(%s) ORDER BY 1,2;' ``` Columns query is even more complicated. It'll be nice to have a simple database view that ships by default that we can query to get his info. I'm also interested to know how other GUI tool devs get this info from the database. Cheers! Amjith --94eb2c14aac892e518056310f30e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi folks,

I'm Amjith. I created=C2= =A0PGCLI, an Openso= urce client for Postgres. It is a command line client with GUI features suc= h as Auto-Completion and Syntax Highlighting.=C2=A0

My goal for participation is gathering consensus to add support in Postgr= es to provide support for accessing metadata about a database without compl= icated queries.

For example, in order to get = a list of tables in a database I have to run a query like this:
<= div>
```
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 SELE= CT=C2=A0 n.nspname schema_name,
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 c.relname table_name=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 FROM=C2=A0=C2=A0=C2=A0 pg_catal= og.pg_class c
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 LEFT JOIN pg_catalog.pg_namespace n
= =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ON n.oid =3D c.relnamespace
=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 WHERE=C2=A0=C2=A0 c.relkind =3D ANY= (%s)
=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ORDER BY 1,2;'
``= `

Columns query is even more complicated.

It'll be nice to have a simple database view that ships= by default that we can query to get his info.

I'm also interested to know how other GUI tool devs get this info fro= m the database.

Cheers!
Amjith
<= /div>
--94eb2c14aac892e518056310f30e--