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

python - Subclassed QStyledItemDelegate ignores Stylesheet -

java - HttpClient 3.1 Connection pooling vs HttpClient 4.3.2 -

SQL: Divide the sum of values in one table with the count of rows in another -