有没有人知道在使用Vtiger webservice执行查询时如何转义单引号(')?
我尝试了以下内容:
我得到的错误是:
{u'error': {u'code': u'QUERY_SYNTAX_ERROR',
u'message': u"Syntax Error on line 1: token 'Connor' Unexpected COLUMNNAME(Connor), expected one of: SEMICOLON",
u'xdebug_message': u"\nWebServiceException: Syntax Error on line 1: token 'Connor' Unexpected COLUMNNAME(Connor), expected one of: SEMICOLON in /var/www/sites/vtigercrm6_test/include/Webservices/VTQL_Parser.php on line 1499\n\nCall Stack:\n 0.0001 221800 1. {main}() /var/www/sites/vtigercrm6_test/webservice.php:0\n 0.0163 3089752 2. OperationManager->runOperation() /var/www/sites/vtigercrm6_test/webservice.php:134\n"},
u'success': False}
谢谢!
答案 0 :(得分:0)
我能够弄明白 - 双单引号!!
select * from Contacts where lastname = 'O''Connor';