Andrew Sullivan wrote:
> On Tue, Feb 10, 2004 at 12:33:10PM -0500, Bruce Momjian wrote:
> > 
> > What do people want to do with the current \copy behavior for stdin? 
> 
> I'd like to hear more discussion of Tom's argument about security
> before the decision is taken.

Tom's point is that you can feed SQL to psql via -f and have \copy input
come from psql's stdin, and you can't insert SQL into psql's stdin:

        prog | psql -f commands.sql test

If commands.sql contains \copy, you can only specify copy data in
'prog', not actual SQL commands.  If you want to mix SQL commands and
\copy data in the same file, you have to use:

        psql test < commands.sql

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  [EMAIL PROTECTED]               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

               http://archives.postgresql.org

Reply via email to