On Fri, 4 Apr 2003, rx wrote:
(This really didn't need to go to all those lists/people, so replying to
general only)
> Can you help me for my another question?
> But when I execute it with "where-condition" in shell as under, come a Error.
>
> PS: VEIrx is database name. Faxeingang is table name. Filename is column name.
>
> TuxFax:~ # echo 'select * from "Faxeingang" where "Filename"=ddf.tif;'|psql VEIrx -U postgres
>
> ERROR: Relation "ddf" does not exist
Right because that's select * from "Faxeingang" where "Filename" =
ddf.tif; (ie, a reference to a tif column of a table named ddf)
> TuxFax:~ # echo 'select * from "Faxeingang" where "Filename"='ddf.tif';'|psql VEIrx -U postgres
>
> ERROR: Relation "ddf" does not exist
This is probably the same as the above (run just the echo part in your
shell).
> TuxFax:~ # echo 'select * from "Faxeingang" where "Filename"="ddf.tif";'|psql VEIrx -U postgres
>
> ERROR: Attribute 'ddf.tif' not found
This is select * from "Faxeingang" where "Filename" = "ddf.tif"
(ie, a reference to a column named ddf.tif in Faxeingang.
How about something like:
echo "select * from \"Faxeingang\" where \"Filename\"='ddf.tif';"