Post 请求ES数据库错误:json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

2023-11-10

Post 请求ES数据库错误:json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

排除发现是需要检索的字符串包含(()) 等括号字符。导致后面检索式检索出错。

# 错误检索字符串
a = '(Hi)hello '
# 解决1 去掉括号
a = 'Hi hello'
# 解决2 两边加单引号
a = '\'' + a + '\''

.
.
.

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

Post 请求ES数据库错误:json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) 的相关文章

随机推荐