SQL 错误消息: "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 'and type=2' at line 3" SQL 语句: "SELECT `resouces`.* FROM `resouces` WHERE related_id= and type=2" SQL 错误代码: "7335941".

错误原因:

您看到这个错误页面是因为应用程序抛出了没有捕获的异常。

异常的详细内容: exception 'flea_db_exception_sqlquery' with message 'SQL 错误消息: "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 'and type=2' at line 3"
SQL 语句: "SELECT `resouces`.*
FROM `resouces`
WHERE related_id= and type=2"
SQL 错误代码: "7335941".' in /var/www/html/hsj/home/FLEA/FLEA/Db/Exception/SqlQuery.php:55

#0 /var/www/html/hsj/home/FLEA/FLEA/Db/Driver/Mysql.php(230): flea_db_exception_sqlquery('SELECT `resouces`.*
FROM `r ...', 'You have an error in your S ...', 1064)
#1 /var/www/html/hsj/home/FLEA/FLEA/Db/TableDataGateway.php(397): execute('SELECT `resouces`.*
FROM `r ...')
#2 /var/www/html/hsj/home/APP/Controller/product.php(250): findall('related_id= and type=2')
#3 /var/www/html/hsj/home/FLEA/FLEA/Dispatcher/Simple.php(127): actionpreview()
#4 /var/www/html/hsj/home/FLEA/FLEA/Dispatcher/Simple.php(77): _executeaction('product', 'preview', 'Controller_product')
#5 /var/www/html/hsj/home/FLEA/FLEA.php(621): dispatching()
#6 /var/www/html/hsj/home/home.php(42): runmvc()
#7 {main}

Exception: flea_db_exception_sqlquery
Message: SQL 错误消息: "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 'and type=2' at line 3" SQL 语句: "SELECT `resouces`.* FROM `resouces` WHERE related_id= and type=2" SQL 错误代码: "7335941".


Filename: /var/www/html/hsj/home/FLEA/FLEA/Db/Driver/Mysql.php
#7 flea_db_exception_sqlquery::flea_db_exception_sqlquery('SELECT `resouces`.* FROM `r ...', 'You have an error in your S ...', 1064)

Filename: /var/www/html/hsj/home/FLEA/FLEA/Db/TableDataGateway.php
#6 flea_db_driver_mysql::execute('SELECT `resouces`.* FROM `r ...')

Filename: /var/www/html/hsj/home/APP/Controller/product.php
#5 model_resource::findall('related_id= and type=2')

Filename: /var/www/html/hsj/home/FLEA/FLEA/Dispatcher/Simple.php
#4 controller_product::actionpreview()

Filename: /var/www/html/hsj/home/FLEA/FLEA/Dispatcher/Simple.php
#3 flea_dispatcher_simple::_executeaction('product', 'preview', 'Controller_product')

Filename: /var/www/html/hsj/home/FLEA/FLEA.php
#2 flea_dispatcher_simple::dispatching()

Filename: /var/www/html/hsj/home/home.php
#1 flea::runmvc()