When an SQL statement under revisions has an exception, such as deleting a column that does not exist, the foreground does not respond. In fact, there is a response, but the returned data is not JSON data and cannot be parsed by the front-end. Modify pdo. publicfunctionquery ($ SQL) {return $ this-_ connection-quer
When an SQL statement under revisions has an exception, such as deleting a column that does not exist, the foreground does not respond. In fact, there is a response, but the returned data is not JSON data and cannot be parsed by the front-end. Modify pdo. public function query ($ SQL) {return $ this-_ connection-quer
When an SQL statement under revisions has an exception, such as deleting a column that does not exist, the foreground does not respond. In fact, there is a response, but the returned data is not JSON data and cannot be parsed by the front-end. Modify the public function query ($ SQL) of the pdo. php file)
Public function query ($ SQL)
{
Return $ this-> _ connection-> query ($ SQL );
}
To:
Public function query ($ SQL)
{
Try {
Return $ this-> _ connection-> query ($ SQL );
}
Catch (Exception $ e ){
Throw new DBV_Exception ($ e-> getMessage (), (int) $ e-> getCode ());
}
}
This bug took a whole night!