PDO 和 MySQL '之间'
本文介绍了PDO 和 MySQL '之间'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试让 PDO 与 MySQL 的之间"一起工作.下面是我的代码:
I'm trying to get PDO to work with a MySQL 'between'. Below is my code:
返回的是一个带有0"或NULL"值的数组.当我硬编码结束日期时,它就像 start_date
设置为 -1,重新调整 end_date
之前的所有行.那么,我在这里做错了什么?
What gets returned is an array with '0' or 'NULL' for values. When I hard code the end date, it acts as if start_date
is set to -1, retuning me all rows before the end_date
. So, what am I doing wrong here?
推荐答案
不要用单引号将值括起来.
Don't wrap the values with single quote.
这篇关于PDO 和 MySQL '之间'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!