{"StatusID":"1","Error":"Register Successfull."}
Run Code Online (Sandbox Code Playgroud)
这是我的JSONObject我不知道如何将它转换为android中的字符串
请告诉我
谢谢.
根据下图,当我使用item.takendate时SimpleDateFormat
我得到了"2016年1月"而不是"2017年1月"
这里发生了什么?请指教.
编辑
但是,当我使用cdate parse返回Date时,它的值从1月1日更改为1月2日
android simpledateformat date-formatting android-date kotlin
我收到了这个错误。
错误:列“名称”不存在第 6 行:
Run Code Online (Sandbox Code Playgroud)SELECT JS, location, location->>Name ^ SQL state: 42703 Character: 278
从这个查询
WITH JsonTable AS
(
SELECT
'[
{
"Id":1,
"Name":"A01",
"Address":"aaa",
"SearchVector":null,
"ParentLocationId":null
},
{
"Id":4,
"Name":"B-01",
"Address":"bbb",
"SearchVector":null,
"ParentLocationId":null
}
]'::jsonb AS JS
)
SELECT JS, location, location->>Name
FROM JsonTable, jsonb_array_elements(JS) x (location)
Run Code Online (Sandbox Code Playgroud)
如何选择 JSON 值?
<!DOCTYPE html>
<html>
<body>
<p id="demo">Click the button to locate where in the string a specifed value occurs.</p>
<button onclick="myFunction()">Try it</button>
<script>
function myFunction()
{
var a =" picture";
a.replace(" ","");
var n=a.indexOf(" ");
document.getElementById("demo").innerHTML= n+a+n;
}
</script>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
我想从上面示例中的"图片"中替换""(空格)
但结果似乎不是替换为replace命令.
替换后结果应该是"-1picture-1"但它是"0 picture0"
在图片前面有一个空格.(我使用.indexOf("")来表示
变量中有空格或不是-1意味着它没有)
它发生了什么?请指教
android ×2
android-date ×1
arrays ×1
html ×1
javascript ×1
json ×1
kotlin ×1
postgresql ×1
sql ×1