Viewing a response to: @oflyhigh/mssql-json
我是用这样分开。 ... <pre><code> JSON_VALUE(cm.json_metadata,'$.tags[0]') tag1, JSON_VALUE(cm.json_metadata,'$.tags[1]') tag2, JSON_VALUE(cm.json_metadata,'$.tags[2]') tag3, JSON_VALUE(cm.json_metadata,'$.tags[3]') tag4, JSON_VALUE(cm.json_metadata,'$.tags[4]') tag5 from Comments cm WITH (NOLOCK) where ... </code></pre> 也是不久前上网找到的。
author | ace108 |
---|---|
permlink | re-oflyhigh-mssql-json-20170815t151926237z |
category | cn |
json_metadata | {"tags":["cn"],"app":"steemit/0.1"} |
created | 2017-08-15 15:19:27 |
last_update | 2017-08-15 15:20:12 |
depth | 1 |
children | 3 |
last_payout | 2017-08-22 15:19:27 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 6.277 HBD |
curator_payout_value | 2.090 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 325 |
author_reputation | 1,244,856,666,250,146 |
root_title | 请MSSQL高手指点一下JSON的问题 |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 11,888,872 |
net_rshares | 2,436,474,317,012 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
joythewanderer | 0 | 7,960,758,023 | 5% | ||
magicmonk | 0 | 0 | 100% | ||
warofcraft | 0 | 73,518,085,436 | 50% | ||
oflyhigh | 0 | 2,354,995,473,553 | 100% |
就好象我用于中日韩报告这样 [📊🌏中日韩龙虎榜自20170811 | CJK Top Pending Payout Post since 20170811 (by @ace108)](https://steemit.com/steemit-stats/@ace108/20170812-or-cjk-top-pending-payout-post-since-20170812-by-ace108) 补充... <pre><code> where ( ( JSON_VALUE(cm.json_metadata,'$.tags[4]') in ('cn','china') ) or ( JSON_VALUE(cm.json_metadata,'$.tags[3]') in ('cn','china') ) or ( JSON_VALUE(cm.json_metadata,'$.tags[2]') in ('cn','china') ) or ( JSON_VALUE(cm.json_metadata,'$.tags[1]') in ('cn','china') ) or ( JSON_VALUE(cm.json_metadata,'$.tags[0]') in ('cn','china') ) or </code></pre>
author | ace108 |
---|---|
permlink | re-ace108-re-oflyhigh-mssql-json-20170815t152438952z |
category | cn |
json_metadata | {"tags":["cn"],"links":["https://steemit.com/steemit-stats/@ace108/20170812-or-cjk-top-pending-payout-post-since-20170812-by-ace108"],"app":"steemit/0.1"} |
created | 2017-08-15 15:24:39 |
last_update | 2017-08-15 15:26:54 |
depth | 2 |
children | 0 |
last_payout | 2017-08-22 15:24:39 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.542 HBD |
curator_payout_value | 0.181 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 612 |
author_reputation | 1,244,856,666,250,146 |
root_title | 请MSSQL高手指点一下JSON的问题 |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 11,889,323 |
net_rshares | 211,016,453,087 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
magicmonk | 0 | 0 | 100% | ||
gentlebot | 0 | 211,016,453,087 | 100% |
感谢分享,这个我有考虑过 对steemit而言也算是个好办法,毕竟标签数目不超过五个 你这连实现例子都给了 大大的👍
author | oflyhigh |
---|---|
permlink | re-ace108-re-oflyhigh-mssql-json-20170815t160104411z |
category | cn |
json_metadata | {"tags":["cn"],"app":"steemit/0.1"} |
created | 2017-08-15 16:01:06 |
last_update | 2017-08-15 16:01:06 |
depth | 2 |
children | 1 |
last_payout | 2017-08-22 16:01:06 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.060 HBD |
curator_payout_value | 0.019 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 59 |
author_reputation | 6,480,446,559,984,510 |
root_title | 请MSSQL高手指点一下JSON的问题 |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 11,892,698 |
net_rshares | 23,503,781,683 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
magicmonk | 0 | 23,503,781,683 | 100% |
不客气。谢谢你的👍
author | ace108 |
---|---|
permlink | re-oflyhigh-re-ace108-re-oflyhigh-mssql-json-20170815t231851722z |
category | cn |
json_metadata | {"tags":["cn"],"app":"steemit/0.1"} |
created | 2017-08-15 23:18:57 |
last_update | 2017-08-15 23:18:57 |
depth | 3 |
children | 0 |
last_payout | 2017-08-22 23:18:57 |
cashout_time | 1969-12-31 23:59:59 |
total_payout_value | 0.000 HBD |
curator_payout_value | 0.000 HBD |
pending_payout_value | 0.000 HBD |
promoted | 0.000 HBD |
body_length | 9 |
author_reputation | 1,244,856,666,250,146 |
root_title | 请MSSQL高手指点一下JSON的问题 |
beneficiaries | [] |
max_accepted_payout | 1,000,000.000 HBD |
percent_hbd | 10,000 |
post_id | 11,926,079 |
net_rshares | 0 |
author_curate_reward | "" |
voter | weight | wgt% | rshares | pct | time |
---|---|---|---|---|---|
magicmonk | 0 | 0 | 100% |