David Fetter wrote: > On Wed, Nov 14, 2007 at 05:15:20PM -0300, Alvaro Herrera wrote: > > Peter Eisentraut wrote: > > > Letting psql execute a script file that is really a directory > > > doesn't complain at all: > > > > > > $ psql -f /tmp > > > > > > Should we do some kind of stat() before opening the file and abort > > > if it's a directory? > > > > Actually anything other than a plain file, right? (Do we really > > want to be able to psql -f a_pipe?) > > Yes, I have seen people use just this technique.
Interesting. Why not just use a standard shell pipe from the command writing into the named pipe, instead of piping through it? -- Alvaro Herrera http://www.flickr.com/photos/alvherre/ "Having your biases confirmed independently is how scientific progress is made, and hence made our great society what it is today" (Mary Gardiner) ---------------------------(end of broadcast)--------------------------- TIP 2: Don't 'kill -9' the postmaster