从2gis API我得到以下JSON字符串.
{
"api_version": "1.3",
"response_code": "200",
"id": "3237490513229753",
"lon": "38.969916127827",
"lat": "45.069889625267",
"page_url": null,
"name": "ATB",
"firm_group": {
"id": "3237499103085728",
"count": "1"
},
"city_name": "Krasnodar",
"city_id": "3237585002430511",
"address": "Turgeneva, 172/1",
"create_time": "2008-07-22 10:02:04 07",
"modification_time": "2013-08-09 20:04:36 07",
"see_also": [
{
"id": "3237491513434577",
"lon": 38.973110606808,
"lat": 45.029031222211,
"name": "Advance",
"hash": "5698hn745A8IJ1H86177uvgn94521J3464he26763737242Cf6e654G62J0I7878e",
"ads": {
"sponsored_article": {
"title": "Center "ADVANCE"",
"text": "Business.English."
},
"warning": null
}
}
]
}
Run Code Online (Sandbox Code Playgroud)
但Python不承认它:
json.loads(firm_str)
Run Code Online (Sandbox Code Playgroud)
期待,分隔符:第1行第3646行(字符3645)
它看起来像引号中的问题:"标题":"中心"ADVANCE""
如何在Python中自动修复它?
请解释一下如何在oracle中使用cursor for loop.
如果我使用下一个代码,一切都很好.
for rec in (select id, name from students) loop
-- do anything
end loop;
Run Code Online (Sandbox Code Playgroud)
但是如果我为这个sql语句定义变量,它就不起作用.
v_sql := 'select id, name from students';
for rec in v_sql loop
-- do anything
end loop;
Run Code Online (Sandbox Code Playgroud)
错误:PLS-00103
我知道在python 3.x中我可以使用非ASCII标识符(PEP 3131).
x1 = 2
x2 = 4
?x = x2 - x1
print(?x)
Run Code Online (Sandbox Code Playgroud)
python 2.7中有这样的功能吗?也许,是否有人将其移植到2.x分支?
我有两个提交多行消息.但是在github的麻烦案例中我只看到第一行.
commit da202cdb5085290a6498c434a0d9388d880fe8c8
Date: Tue Oct 1 16:30:02 2013 +0200
Line 1
Line 2
commit c58f91213428728836b1364ecc111ba71e7c91c6
Date: Tue Oct 1 15:47:12 2013 +0200
[f] unique primary key for id in picture
[+] join_db script
Run Code Online (Sandbox Code Playgroud)
https://github.com/antofa/autowp_test/commits/dev
我使用下一个命令进行提交:
git commit -F commit_message.txt
git commit -m"Line 1"-m"Line 2"
github可以使用多行提交消息吗?