Search Postgresql Archives

Re: Bash function from psql (v14)

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

 



What problem are you trying to solve? If you tell us that, we can guide you to some better solutions.

There are numerous issues here, but the most important are:

1) Calling a shell via \! invokes an entirely new process: there is no link to the parent or grandparent process

2) The run-bash-function must be declared before being called, so that bash code was never going to work anyway. In other words, this is valid:

run-bash-function() { echo "Here we are"; }

run-bash-function

This version is not:

run-bash-function

run-bash-function() { echo "Here we are"; }


Cheers,
Greg


[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 Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux