Re: [GENERAL] SQL Path in psql

2013-09-08 Thread BladeOfLight16
On Fri, Sep 6, 2013 at 1:58 PM, David Kerr wrote: > I suspect this feature makes more sense on a windows platform. On linux > where we can > go psql -f ${SQLPATH}/file.sql . it becomes less pressing. Even Oracle > on unix/linux where you can go sqlplus < makes > it less a requirement. > I don't

Re: [GENERAL] SQL Path in psql

2013-09-06 Thread Rob Sargentg
On 09/06/2013 11:05 AM, miles wrote: Bobby Dewitt wrote I come from an Oracle background and I am fairly new to Postgres. Oracle's command line utility (SQL*Plus) uses an environment variable called SQLPATH to search the given directories for SQL scripts that the user calls to execute using a me

Re: [GENERAL] SQL Path in psql

2013-09-06 Thread David Johnston
lup wrote >> >> > I wonder if this would at least get the full path on-screen for a c/p > \! for d in $SQLPATH; do find $d -name > > ; done > > That said, I would down-vote this suggestion. I tend to put sql files > in amongst my various project dirs and maintaining the envvar isn't > w

Re: [GENERAL] SQL Path in psql

2013-09-06 Thread David Kerr
On Fri, Sep 06, 2013 at 10:45:26AM -0700, David Johnston wrote: - lup wrote - >> - >> - > I wonder if this would at least get the full path on-screen for a c/p - > \! for d in $SQLPATH; do find $d -name - > - > ; done - > - > That said, I would down-vote this suggestion. I tend to put sql

Re: [GENERAL] SQL Path in psql

2013-09-06 Thread Miles Pomeroy
In my opinion, the use of such a feature is to make simple, commonly used scripts available from wherever you start up psql and no matter what database you are connecting to. On Oracle/SQL*Plus I have used this feature to create simple scripts that replicate informational backslash commands in psql

Re: [GENERAL] SQL Path in psql

2013-09-06 Thread miles
Bobby Dewitt wrote > I come from an Oracle background and I am fairly new to Postgres. > Oracle's command line utility (SQL*Plus) uses an environment variable > called SQLPATH to search the given directories for SQL scripts that the > user calls to execute using a method similar to the \i meta-com

[GENERAL] SQL Path in psql

2011-05-20 Thread Bobby Dewitt
I come from an Oracle background and I am fairly new to Postgres. Oracle's command line utility (SQL*Plus) uses an environment variable called SQLPATH to search the given directories for SQL scripts that the user calls to execute using a method similar to the \i meta-command in psql. This allo