Re: PostgreSQL or pl/psSQL equivalent to MS SQL Server's

From: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
To: <Trent(dot)Mera(at)PeopleFirst(dot)com>
Cc: <pgsql-sql(at)postgresql(dot)org>
Subject: Re: PostgreSQL or pl/psSQL equivalent to MS SQL Server's
Date: 2003-07-24 17:31:54
Message-ID: Pine.LNX.4.33.0307241130050.25837-100000@css120.ihs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Thu, 24 Jul 2003 Trent(dot)Mera(at)PeopleFirst(dot)com wrote:

> Does anyone know of the PostgreSQL or pl/psSQL equivalent to MS SQL Server's
> xp_cmdshell? This is the command that allows you issue command-line
> statements from within SQL, e.g., you would do xp_cmdshell 'dir c:\' if you
> wanted to see the contents of the c: drive.

That can only be done inside an untrusted procedural language. plpgsql is
trusted, so it can't do that type of thing.

C, pltclu, plprelu, and, as of 7.4 plpython will let you do that.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Greg Stark 2003-07-24 18:35:46 Re: min() and NaN
Previous Message Trent.Mera 2003-07-24 17:29:25 PostgreSQL or pl/psSQL equivalent to MS SQL Server's xp_cmdshell?