From: | Hans Schou <hans(dot)schou(at)gmail(dot)com> |
---|---|
To: | pgsql-general <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Re: Feature proposal, DBURL: psql pgsql://joe:p4zzw0rd@example.org:2345/dbname |
Date: | 2017-07-05 15:26:38 |
Message-ID: | CAApBw36PW9EP9bkrxh7Pw3=T9zgAq5aObreKMWudoFav2d6+xQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
2017-07-05 16:29 GMT+02:00 Thomas Kellerer <spam_eater(at)gmx(dot)net>:
> Hans Schou schrieb am 05.07.2017 um 14:27:
> > The dburl (or dburi) has become common to use by many systems
> > connecting to a database. The feature is that one can pass all
> > parameters in a string, which has similar pattern as http-URI do.
> >
> > Especially when using psql in a script, having the credentials in one
> string is convenient.
> >
> > The syntax could be:
> > [scheme[<+>dsn]]://[[username[:[password]](at)][host][:port][/[
> dbname][/[[table[/[column[,column...]*]]]|sql]]]
>
> Besides the fact that something like that is already possible:
>
> What's the use of "table" and "column" in the URI? You connect to a
> database, not to a table.
>
With 'table' the idea was to do a "SELECT * FROM table" on that.
With 'column' added only that or those columns would be listed.
The "sql" part in the end was supposed to be a SQL-statement to be
executed, like:
psql "postgresql://localhost/dbname/INSERT INTO foo VALUES($RANDOM)"
which should be equal to
echo "INSERT INTO foo VALUES($RANDOM)" | psql
postgresql://localhost/dbname
./hans
From | Date | Subject | |
---|---|---|---|
Next Message | Moreno Andreo | 2017-07-05 15:29:19 | Re: [SPAM] Re: Invalid field size |
Previous Message | David G. Johnston | 2017-07-05 15:23:04 | Re: building extension with large string inserts |