[10501] PDOException in Connection.php line 457

SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

  1. // 调试结束
  2. $this->debug(false);
  3. $this->numRows = $this->PDOStatement->rowCount();
  4. return $this->numRows;
  5. } catch (\PDOException $e) {
  6. if ($this->config['break_reconnect'] && $this->isBreak($e)) {
  7. return $this->close()->execute($sql, $bind);
  8. }
  9. throw new PDOException($e, $this->config, $this->getLastsql());
  10. }
  11. }
  12. /**
  13. * 根据参数绑定组装最终的SQL语句 便于调试
  14. * @access public
  15. * @param string $sql 带参数绑定的sql语句
  16. * @param array $bind 参数绑定列表
  17. * @return string

Call Stack

  1. in Connection.php line 457
  2. at Connection->execute('update tp_archives s...', []) in Query.php line 239
  3. at Query->execute('update tp_archives s...') in Article.php line 58
  4. at Article->index()
  5. at ReflectionMethod->invokeArgs(object(Article), []) in App.php line 224
  6. at App::invokeMethod([object(Article), 'index'], []) in App.php line 392
  7. at App::module([null, 'article', 'index'], ['app_namespace' => 'app', 'app_debug' => true, 'app_trace' => false, ...], false) in App.php line 130
  8. at App::run() in start.php line 18
  9. at require('/usr/home/hyu05001/h...') in default.php line 30

Exception Datas

PDO Error Info
SQLSTATE 42000
Driver Error Code 1064
Driver Error Message You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
Database Status
Error Code 10501
Error Message SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
Error SQL update tp_archives set click =click+1 where id =
Database Config
type mysql
hostname hdm-103.hichina.com
database hdm1030167_db
username hdm1030167
password Dfh123456
hostport
dsn
params []
charset utf8
prefix tp_
debug true
deploy 0
rw_separate false
master_num 1
slave_no
fields_strict true
result_type 2
resultset_type array
auto_timestamp false
datetime_format Y-m-d H:i:s
sql_explain false
builder
query \think\db\Query
break_reconnect false

Environment Variables

GET Dataempty
POST Dataempty
Filesempty
Cookies
PHPSESSID v5qjul0cf2lcrku7dl8kdmp9p3
Sessionempty
Server/Request Data
DOCUMENT_ROOT /usr/home/hyu05001/htdocs
GATEWAY_INTERFACE CGI/1.1
HTTP_ACCEPT */*
HTTP_ACCEPT_ENCODING gzip
HTTP_COOKIE PHPSESSID=v5qjul0cf2lcrku7dl8kdmp9p3
HTTP_HOST www.dawn-biotech.com.cn
HTTP_USER_AGENT Mozilla/5.0 (compatible; AhrefsBot/7.0; +http://ahrefs.com/robot/)
PATH /bin
PHPRC /var/www/php55/hichina_ini/hyu05001
QUERY_STRING
REDIRECT_DOCUMENT_ROOT /usr/home/hyu05001/htdocs
REDIRECT_GATEWAY_INTERFACE CGI/1.1
REDIRECT_HTTP_ACCEPT */*
REDIRECT_HTTP_ACCEPT_ENCODING gzip
REDIRECT_HTTP_COOKIE PHPSESSID=v5qjul0cf2lcrku7dl8kdmp9p3
REDIRECT_HTTP_HOST www.dawn-biotech.com.cn
REDIRECT_HTTP_USER_AGENT Mozilla/5.0 (compatible; AhrefsBot/7.0; +http://ahrefs.com/robot/)
REDIRECT_PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
REDIRECT_PATH_INFO /aid/363.html
REDIRECT_PATH_TRANSLATED redirect:/default.php/aid/363.html/363.html
REDIRECT_QUERY_STRING
REDIRECT_REMOTE_ADDR 173.232.241.114
REDIRECT_REMOTE_PORT 44946
REDIRECT_REQUEST_METHOD GET
REDIRECT_REQUEST_URI /article/aid/363.html
REDIRECT_SCRIPT_FILENAME /usr/home/hyu05001/htdocs/article
REDIRECT_SCRIPT_NAME /article
REDIRECT_SERVER_ADDR 10.21.112.12
REDIRECT_SERVER_ADMIN webmaster@dawn-biotech.com.cn
REDIRECT_SERVER_NAME www.dawn-biotech.com.cn
REDIRECT_SERVER_PORT 80
REDIRECT_SERVER_PROTOCOL HTTP/1.1
REDIRECT_SERVER_SIGNATURE
REDIRECT_SERVER_SOFTWARE Apache
REDIRECT_STATUS 200
REDIRECT_TZ Asia/Shanghai
REDIRECT_UNIQUE_ID ZoCHegoVcAwAGdDKbREAAAAN
REDIRECT_URL /article/aid/363.html
REMOTE_ADDR 173.232.241.114
REMOTE_PORT 44946
REQUEST_METHOD GET
REQUEST_URI /article/aid/363.html
SCRIPT_FILENAME /usr/home/hyu05001/htdocs/default.php
SCRIPT_NAME /default.php
SERVER_ADDR 10.21.112.12
SERVER_ADMIN webmaster@dawn-biotech.com.cn
SERVER_NAME www.dawn-biotech.com.cn
SERVER_PORT 80
SERVER_PROTOCOL HTTP/1.1
SERVER_SIGNATURE
SERVER_SOFTWARE Apache
TZ Asia/Shanghai
UNIQUE_ID ZoCHegoVcAwAGdDKbREAAAAN
ORIG_PATH_INFO /article/aid/363.html
ORIG_PATH_TRANSLATED /usr/home/hyu05001/htdocs/default.php
PHP_SELF /default.php
REQUEST_TIME_FLOAT 1719699322.2714
REQUEST_TIME 1719699322
PATH_INFO /article/aid/363.html
Environment Variablesempty
ThinkPHP Constants
APP_PATH /usr/home/hyu05001/htdocs/application/
ADMINIMG /usr/home/hyu05001/htdocs/public/static/admin/uploads/cateimg/
INDEXIMGS /usr/home/hyu05001/htdocs/public/static/index/uploads/cateimg/
ADMIN_STATIC /usr/home/hyu05001/htdocs/public/static/admin/
INDEXIMG /usr/home/hyu05001/htdocs/public/static/index/uploads/img/
INDEXATT /usr/home/hyu05001/htdocs/public/static/index/uploads/att/
INDEXAD /usr/home/hyu05001/htdocs/public/static/index/uploads/ad/
APP_DEBUG true
THINK_VERSION 5.0.6
THINK_START_TIME 1719699322.2719
THINK_START_MEM 250784
EXT .php
DS /
THINK_PATH /usr/home/hyu05001/htdocs/thinkphp/
LIB_PATH /usr/home/hyu05001/htdocs/thinkphp/library/
CORE_PATH /usr/home/hyu05001/htdocs/thinkphp/library/think/
TRAIT_PATH /usr/home/hyu05001/htdocs/thinkphp/library/traits/
ROOT_PATH /usr/home/hyu05001/htdocs/
EXTEND_PATH /usr/home/hyu05001/htdocs/extend/
VENDOR_PATH /usr/home/hyu05001/htdocs/vendor/
RUNTIME_PATH /usr/home/hyu05001/htdocs/runtime/
LOG_PATH /usr/home/hyu05001/htdocs/runtime/log/
CACHE_PATH /usr/home/hyu05001/htdocs/runtime/cache/
TEMP_PATH /usr/home/hyu05001/htdocs/runtime/temp/
CONF_PATH /usr/home/hyu05001/htdocs/application/
CONF_EXT .php
ENV_PREFIX PHP_
IS_CLI false
IS_WIN false