Feature Request

Started by Q Beukesalmost 20 years ago6 messages
#1Q Beukes
pgsql-dev@list.za.net

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hey,

This might not be much, but can there maybe be a future feature for
having a shortcut to "set search_path='schema-name';"
similiar to \c dbname ??

Thx
Quintin Beukes
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iQEVAwUBQ/nBC7EDZDQ16UzTAQJsPQf+JHKB/oYppYH1vSD/ar2YQEiTgs2mHsbc
FfjftZTykf+P7jrA78ZrttlQEnW09A1Ul3qvNmAGDNs7n2XGHZH7q7539RMjh1h6
Lb5PUwbVtFehUbcMNkocIQsJx/rs6kKfB2sau5ZkrOK+NIyHiTYU3hXpSj2v5Zp5
nAcf8arNlL0zKPhoZCTg4eP0Bx8OvfJeMSAnpnuc17bnMqm8EWAenjr86LFb/L1L
mW7+x5vo/ZIoj8FZVKx3Iiy5Zu2K3ylZ8gqGbL9H1i/xTmWRhypQMwMxZ3suiAMT
MLlnC1iYRj2x+aTA0RbYdVJqcS/hjFwbi8T0JI/GOtHxPgyDMJwbEQ==
=ma34
-----END PGP SIGNATURE-----

#2Peter Eisentraut
peter_e@gmx.net
In reply to: Q Beukes (#1)
Re: Feature Request

Am Montag, 20. Februar 2006 14:15 schrieb Q Beukes:

Hey,

This might not be much, but can there maybe be a future feature for
having a shortcut to "set search_path='schema-name';"
similiar to \c dbname ??

pei=# \set X 'set search_path = '
pei=# :X public;
SET
pei=# show search_path;
search_path
-------------
public

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

#3Adam Witney
awitney@sgul.ac.uk
In reply to: Peter Eisentraut (#2)
Re: Feature Request

On 20/2/06 1:26 pm, "Peter Eisentraut" <peter_e@gmx.net> wrote:

Am Montag, 20. Februar 2006 14:15 schrieb Q Beukes:

Hey,

This might not be much, but can there maybe be a future feature for
having a shortcut to "set search_path='schema-name';"
similiar to \c dbname ??

pei=# \set X 'set search_path = '
pei=# :X public;
SET
pei=# show search_path;
search_path
-------------
public

That seems quite handy to know! can these be saved anywhere such that I
don't have to run the \set <...> command every session?

Thanks

Adam

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

#4Jonah H. Harris
jonah.harris@gmail.com
In reply to: Adam Witney (#3)
Re: Feature Request

ALTER USER bob SET search_path ...?

On 2/20/06, Adam Witney <awitney@sgul.ac.uk> wrote:

On 20/2/06 1:26 pm, "Peter Eisentraut" <peter_e@gmx.net> wrote:

Am Montag, 20. Februar 2006 14:15 schrieb Q Beukes:

Hey,

This might not be much, but can there maybe be a future feature for
having a shortcut to "set search_path='schema-name';"
similiar to \c dbname ??

pei=# \set X 'set search_path = '
pei=# :X public;
SET
pei=# show search_path;
search_path
-------------
public

That seems quite handy to know! can these be saved anywhere such that I
don't have to run the \set <...> command every session?

Thanks

Adam

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

--
Jonah H. Harris, Database Internals Architect
EnterpriseDB Corporation
732.331.1324

#5Adam Witney
awitney@sgul.ac.uk
In reply to: Jonah H. Harris (#4)
Re: Feature Request

ALTER USER bob SET search_path ...?

Sorry I didn't mean the search_path example, but I was thinking I could
setup a short cut for a common query, eg:

\set logins <SQL query>
:logins

Could save this such that the short cut is available every time I open psql?

Thanks

Adam

--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.

#6Peter Eisentraut
peter_e@gmx.net
In reply to: Adam Witney (#3)
Re: Feature Request

Am Montag, 20. Februar 2006 14:33 schrieb Adam Witney:

That seems quite handy to know! can these be saved anywhere such that I
don't have to run the \set <...> command every session?

~/.psqlrc

--
Peter Eisentraut
http://developer.postgresql.org/~petere/