kadena-io / chainweb-data

Data ingestion for Chainweb.
BSD 3-Clause "New" or "Revised" License
14 stars 8 forks source link

fix missing number 1 holder #95

Closed trendzetter closed 1 year ago

trendzetter commented 2 years ago

I replaced

cast(ifnull(json_extract(rowdata, '$.balance.decimal'), json_extract(rowdata, '$.balance')) as REAL) as 'balance' with cast( ifnull( ifnull(json_extract(rowdata, '$.balance.decimal'), json_extract(rowdata, '$.balance')), json_extract(rowdata, '$.\$d.balance') ) as REAL) as 'balance'

to add the missing account balances

trendzetter commented 2 years ago

I just saw there are other plans for the richlist.sh such as generating the script. So maybe my changes can't be applied directly as proposed

enobayram commented 1 year ago

@trendzetter thank you for opening this PR, as you've noticed, @emmanueldenloye has refactored richlist generation in https://github.com/kadena-io/chainweb-data/pull/89 which already got merged at this point. I think #89 also addressed this missing case you're fixing in this PR, so I'll close it.