PHP MYSQL select query strip spaces from column -


i have query

mysql_query("select * codes code='222 '"); 

i want strip spaces in column in query should

mysql_query("select * codes code=strippedstring('222 ')" 

what best way this

try

$value=trim('222 '); mysql_query("select * codes code=$value" 

note:- stop using mysql_* deprecated

learn trim()


Comments

Popular posts from this blog

node.js - StackOverflow API not returning JSON -

python - Subclassed QStyledItemDelegate ignores Stylesheet -

php - Laravel 4.1 to Heroku: SQLSTATE[HY000] [2002] No such file or directory -