Search Postgresql Archives

Re: psql & unix env variables

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wednesday, August 29, 2012 12:35:32 PM Little, Douglas wrote:
> Is there a method for having unix env variables incorporated into a psql sql
> statement? Ie
> Export var='dev'
> Psql =c 'select count(*) from $var.customer;'
> 

Use double-quotes, not single-quotes. Bash won't interpolate variables into 
single-quoted strings.


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux