[10501] PDOException in Connection.php line 388

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 ') LIMIT 4' at line 1

  1. $this->PDOStatement->execute();
  2. // 调试结束
  3. $this->debug(false);
  4. // 返回结果集
  5. return $this->getResult($pdo, $procedure);
  6. } catch (\PDOException $e) {
  7. if ($this->isBreak($e)) {
  8. return $this->close()->query($sql, $bind, $master, $pdo);
  9. }
  10. throw new PDOException($e, $this->config, $this->getLastsql());
  11. } catch (\ErrorException $e) {
  12. if ($this->isBreak($e)) {
  13. return $this->close()->query($sql, $bind, $master, $pdo);
  14. }
  15. throw $e;
  16. }
  17. }
  18. /**

Call Stack

  1. in Connection.php line 388
  2. at Connection->query('SELECT `id`,`title`,...', [], false, false) in Query.php line 225
  3. at Query->query('SELECT `id`,`title`,...', [], false, false) in Query.php line 2318
  4. at Query->select() in 6826eff781cfe1762445dd0c6646df97.php line 696
  5. at include('/home/php/landzg_web...') in File.php line 50
  6. at File->read('/home/php/landzg_web...', ['userInfo' => null, 'menu' => ['index' => ['id' => 1, 'title' => '首页', 'model' => 'index', ...], 'loupan' => ['id' => 2, 'title' => '新房', 'model' => 'loupan', ...], 'second' => ['id' => 3, 'title' => '二手房', 'model' => 'second', ...], ...], 'seo' => ['title' => '_依家网', 'keys' => '', 'desc' => ''], ...]) in Template.php line 196
  7. at Template->fetch('/home/php/landzg_web...', ['userInfo' => null, 'menu' => ['index' => ['id' => 1, 'title' => '首页', 'model' => 'index', ...], 'loupan' => ['id' => 2, 'title' => '新房', 'model' => 'loupan', ...], 'second' => ['id' => 3, 'title' => '二手房', 'model' => 'second', ...], ...], 'seo' => ['title' => '_依家网', 'keys' => '', 'desc' => ''], ...], []) in Think.php line 84
  8. at Think->fetch('/home/php/landzg_web...', ['userInfo' => null, 'menu' => ['index' => ['id' => 1, 'title' => '首页', 'model' => 'index', ...], 'loupan' => ['id' => 2, 'title' => '新房', 'model' => 'loupan', ...], 'second' => ['id' => 3, 'title' => '二手房', 'model' => 'second', ...], ...], 'seo' => ['title' => '_依家网', 'keys' => '', 'desc' => ''], ...], []) in View.php line 159
  9. at View->fetch('', ['userInfo' => null, 'menu' => ['index' => ['id' => 1, 'title' => '首页', 'model' => 'index', ...], 'loupan' => ['id' => 2, 'title' => '新房', 'model' => 'loupan', ...], 'second' => ['id' => 3, 'title' => '二手房', 'model' => 'second', ...], ...], 'seo' => ['title' => '_依家网', 'keys' => '', 'desc' => ''], ...], [], []) in Controller.php line 111
  10. at Controller->fetch() in Chuzu.php line 234
  11. at Chuzu->detail()
  12. at ReflectionMethod->invokeArgs(object(Chuzu), []) in App.php line 343
  13. at App::invokeMethod([object(Chuzu), 'detail'], []) in App.php line 612
  14. at App::module([null, 'Chuzu', 'detail'], ['app_debug' => true, 'app_trace' => false, 'app_status' => '', ...], false) in App.php line 456
  15. at App::exec(['type' => 'module', 'module' => [null, 'Chuzu', 'detail'], 'convert' => false], ['app_debug' => true, 'app_trace' => false, 'app_status' => '', ...]) in App.php line 139
  16. at App::run() in start.php line 18
  17. at require('/home/php/landzg_web...') in index.php line 17

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 ') LIMIT 4' 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 ') LIMIT 4' at line 1
Error SQL SELECT `id`,`title`,`img`,`room`,`ting`,`price` FROM `fang_rental` WHERE ( status=1 and estate_id= ) LIMIT 4
Database Config
type mysql
hostname 127.0.0.1
database peng_landzg.com
username root
password yz47030346
hostport 3306
dsn
params []
charset utf8
prefix fang_
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 false
sql_explain false
builder
query \think\db\Query
break_reconnect false

Environment Variables

GET Data
empty
POST Data
empty
Files
empty

Cookies

cityInfo
think:{"id":"1","name":"%E5%8D%97%E5%AE%81","initials":"N","alias":"nn","pid":0,"spid":"0","ordid":"255","status":"1","seo_title":"","seo_keys":"","seo_desc":"","domain":"nn","is_hot":"1","default":"1","zuobiao":"108.328589%2C22.8189"}
Session
empty

Server/Request Data

USER
apache
HOME
/usr/share/httpd
HTTP_HOST
nn.landzg.com
HTTP_USER_AGENT
claudebot
HTTP_ACCEPT
*/*
REDIRECT_STATUS
200
SERVER_NAME
landzg.com
SERVER_PORT
80
SERVER_ADDR
10.1.1.83
REMOTE_PORT
41678
REMOTE_ADDR
3.81.30.41
SERVER_SOFTWARE
nginx/1.20.1
GATEWAY_INTERFACE
CGI/1.1
REQUEST_SCHEME
http
SERVER_PROTOCOL
HTTP/1.1
DOCUMENT_ROOT
/home/php/landzg_web/public
DOCUMENT_URI
/index.php/chuzu/12377.html
REQUEST_URI
/chuzu/12377.html
SCRIPT_NAME
/index.php
CONTENT_LENGTH
CONTENT_TYPE
REQUEST_METHOD
GET
QUERY_STRING
PATH_TRANSLATED
/home/php/landzg_web/public/chuzu/12377.html
PATH_INFO
/chuzu/12377.html
SCRIPT_FILENAME
/home/php/landzg_web/public/index.php
FCGI_ROLE
RESPONDER
PHP_SELF
/index.php/chuzu/12377.html
REQUEST_TIME_FLOAT
1711618556.3974
REQUEST_TIME
1711618556
Environment Variables
empty

ThinkPHP Constants

APP_PATH
/home/php/landzg_web/public/../application/
HX_PATH
/home/php/landzg_web/public/../extend/
THINK_VERSION
5.0.9
THINK_START_TIME
1711618556.3975
THINK_START_MEM
392696
EXT
.php
DS
/
THINK_PATH
/home/php/landzg_web/thinkphp/
LIB_PATH
/home/php/landzg_web/thinkphp/library/
CORE_PATH
/home/php/landzg_web/thinkphp/library/think/
TRAIT_PATH
/home/php/landzg_web/thinkphp/library/traits/
ROOT_PATH
/home/php/landzg_web/
EXTEND_PATH
/home/php/landzg_web/extend/
VENDOR_PATH
/home/php/landzg_web/vendor/
RUNTIME_PATH
/home/php/landzg_web/runtime/
LOG_PATH
/home/php/landzg_web/runtime/log/
CACHE_PATH
/home/php/landzg_web/runtime/cache/
TEMP_PATH
/home/php/landzg_web/runtime/temp/
CONF_PATH
/home/php/landzg_web/public/../application/
CONF_EXT
.php
ENV_PREFIX
PHP_
IS_CLI
false
IS_WIN
false