title: Execute a Bash script (Shell Script) from postgres function/procedure/trigger
body: <pre><code>CREATE or replace FUNCTION test() RETURNS boolean AS $$
  $filename = '/home/postgres';
  if (-e $filename) { 
  exec /home/postgres/test.sh &amp;
  return true; }
  return false;
  $$ LANGUAGE plperlu;
  </code></pre>
  
  <p>exec /home/postgres/test.sh &amp;  its showing syntax error.
  Could you please help how to call bash script into postgres funtion/procedure</p>