Re: [despammed] [SQL] Insert psql commands inside a script

2005-04-23 Thread Geoffrey
Michael Fuhr wrote: On Sat, Apr 23, 2005 at 08:15:48AM -0400, Geoffrey wrote: Or you can do the following: psql database < sqlcode where sqlcode contains your sql. That command redirects the standard input from the file named sqlcode; the requirement says NOT to use an external file. My bad, I mis

Re: [despammed] [SQL] Insert psql commands inside a script

2005-04-23 Thread Michael Fuhr
On Sat, Apr 23, 2005 at 08:15:48AM -0400, Geoffrey wrote: > > Or you can do the following: > > psql database < sqlcode > > where sqlcode contains your sql. That command redirects the standard input from the file named sqlcode; the requirement says NOT to use an external file. -- Michael Fuhr

Re: [despammed] [SQL] Insert psql commands inside a script

2005-04-23 Thread Geoffrey
Andreas Kretschmer wrote: am 21.04.2005, um 17:19:23 -0500 mailte Letnes, David G. folgendes: I have used the psql -f /tmp/SelectCommands.sql before, but now I want to put the sql statement right in the shell script. I haven't had any luck. Is there a command I can use that will not point to a

Re: [despammed] [SQL] Insert psql commands inside a script

2005-04-22 Thread Andreas Kretschmer
am 21.04.2005, um 17:19:23 -0500 mailte Letnes, David G. folgendes: > > I have used the psql -f /tmp/SelectCommands.sql before, but now I want > to put the sql statement right in the shell script. I haven't had any > luck. Is there a command I can use that will not point to a file for > the s

Re: [SQL] Insert psql commands inside a script

2005-04-22 Thread Michael Fuhr
On Thu, Apr 21, 2005 at 05:19:23PM -0500, Letnes, David G. wrote: > > I have used the psql -f /tmp/SelectCommands.sql before, but now I want > to put the sql statement right in the shell script. I haven't had any > luck. Is there a command I can use that will not point to a file for > the sql

[SQL] Insert psql commands inside a script

2005-04-22 Thread Letnes, David G.
Title: Insert psql commands inside a script   I have used the psql -f /tmp/SelectCommands.sql before, but now I want to put the sql statement right in the shell script.  I haven't had any luck.  Is there a command I can use that will not point to a file for the sql instructions but right on