fix exponential number notation
This commit is contained in:
parent
edfa828c2a
commit
655c3b4032
@ -118,6 +118,9 @@ function get_marketdata_coinmarketcap {
|
|||||||
else
|
else
|
||||||
egrep -h "^[1-9][0-9][0-9][0-9]-[0-1][0-9]-[0-9][0-9].*,[0-9]" "${f_targetcsvtmp}" | sort -k1,2 -t, -u >"$f_targetcsv"
|
egrep -h "^[1-9][0-9][0-9][0-9]-[0-1][0-9]-[0-9][0-9].*,[0-9]" "${f_targetcsvtmp}" | sort -k1,2 -t, -u >"$f_targetcsv"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# change exponential notation to normal notation
|
||||||
|
g_num_exponential2normal_file "${f_targetcsv}"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -151,7 +154,7 @@ function get_marketdata_coinmarketcap_ids {
|
|||||||
f_latest_date_seconds=$(date -d "$f_latest_date" +%s)
|
f_latest_date_seconds=$(date -d "$f_latest_date" +%s)
|
||||||
if [ $f_latest_date_seconds_now -lt $f_latest_date_seconds ]
|
if [ $f_latest_date_seconds_now -lt $f_latest_date_seconds ]
|
||||||
then
|
then
|
||||||
jq -r '.data | .symbol + "," + (.id|tostring) + "," + .name + "," + (.quotes[].quote|.marketCap|tostring)' "$g_tmp/get_marketdata_coinmarketcap_ids.json" | head -n 1
|
jq -r '.data | .symbol + "," + (.id|tostring) + "," + .name + "," + (.quotes[].quote|.marketCap|tostring)' "$g_tmp/get_marketdata_coinmarketcap_ids.json" | grep -vi ",0e-" | head -n 1
|
||||||
fi
|
fi
|
||||||
done | egrep --line-buffered '^.+,[0-9]*,' >"$f_target_loop"
|
done | egrep --line-buffered '^.+,[0-9]*,' >"$f_target_loop"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user