querySinglePointHistData.sh 616 B

12345678910111213141516171819202122
  1. #!/usr/bin/env bash
  2. ROOT=$(cd `dirname $0`/../../; pwd)
  3. cd $ROOT
  4. source $ROOT/shell/tsdb/common.sh
  5. pointCount=1
  6. pointIndex=1
  7. for days in 1 2 3 4 7 15
  8. do
  9. echo "----test query range days:$days"
  10. beginDate="2018-06-01 00:00:00"
  11. echo beginDate:beginDate
  12. endDate=$(date -d "${beginDate} ${days} days" +"%Y-%m-%d %H:%M:%S")
  13. echo endDate:$endDate
  14. java -cp ./lib/influxdb.jar demo.query.histQuery.QuerySinglePointHistData \
  15. --host $host --pointNamePrefix pointName1_ --pointIndex $pointIndex \
  16. --beginDate "$beginDate" --endDate "$endDate" \
  17. --showQueryResult 0 2>&1 | tee -a ./log/influxdb/out.log
  18. done