Mysql Select Where id<100 -
i'm trying query in php:
$sql= "select pcampo6 productos id >= 100";
this error get:
invalid query: have error in sql syntax; check manual corresponds mysql server version right syntax use near '= 100' @ line 1
i tried :
$sql = "select `pcampo6` productos eliminado=0 , `id` >= 101"; $sql = "select 'pcampo6' productos eliminado=0 , 'id' >= 101"; $sql = "select pcampo6 productos eliminado=0 , id >= '101'";
there nothing wrong query posted.
- if
id
column not integer type, try using single quotes around value
the error coming elsewhere in code not showing us.
Comments
Post a Comment