Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/mysql/59.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Zend_表删除引号_Php_Mysql_Zend Framework - Fatal编程技术网

Php Zend_表删除引号

Php Zend_表删除引号,php,mysql,zend-framework,Php,Mysql,Zend Framework,这就是: …和(c.user\u id不在('2,1'))因此我想删除不在(2,1) 有没有办法得到这样的输出不在(2,1)中您需要传递数组,而不是字符串 ->where("c.user_id NOT IN (?)", $not_in_array) 如果您只有一个字符串-explode()it: $not_in_array = explode(',', $not_in); 这样解决: ->where("c.user_id NOT IN (?)",new Zend_Db_Expr(

这就是:

…和(c.user\u id不在('2,1'))
因此我想删除
不在(2,1)


有没有办法得到这样的输出
不在(2,1)中

您需要传递数组,而不是字符串

->where("c.user_id NOT IN (?)", $not_in_array)
如果您只有一个字符串-
explode()
it:

$not_in_array = explode(',', $not_in);
这样解决:

->where("c.user_id NOT IN (?)",new Zend_Db_Expr($exclude))

@Uffo:ctrl+f表示
。\u选择WhereArray
测试PS:“不工作”不是问题explanation@Uffo:当“testasdocumentation”语句起作用时,这实际上是一个很好的例子
->where("c.user_id NOT IN (?)",new Zend_Db_Expr($exclude))