此代码在PGAdmin上输出预期结果
select * from reports where manifesto_id = ' ' order by report_id
但是当我使用像这样的PHP pg_query_params运行它时
pg_query_params($connection,'select * from reports where manifesto_id = $1 order by report_id',array(' '));
我收到错误
PHP Parse错误:语法错误,意外''按report_id排序''(T_CONSTANT_ENCAPSED_STRING),期待','或')'
我尝试过使用manifesto_id为Null,但显然是
' ' != Null
所以我没有得到预期的结果。有什么帮助吗?