You must write
select * from table where field like '$txt';
The symbol ' must be around the variable.
Sorry for bad English.
Good luck,
Natalya S. Makushina
Webmaster RTSoft Co.
Telephone: (095)742-68-28
E-mail: mak@rtsoft.msk.ru
WWW: http://www.rtsoft.ru
From : amarof [SMTP:amarof@marwan.ac.ma]
Date : 5 июня 1999 г. 19:45
To : pgsql-general@postgreSQL.org
Subject : [GENERAL] ' syntax (using PHP3)
i got your answers about the syntax, it works with the strings, but when
etat takes a variable value, it gives a parser error. example : select *
from table where field like $txt
the error occurs when txt takes the value (doctortat d'etat).
thanks