 if [[ $# -ne 2 ]];then
     echo 'Usage:'$0' <startdate> <enddate>'
     exit
 fi

 startdate=`date -d "$1" +%Y-%m-%d`
 enddate=`date -d "$2" +%Y-%m-%d`

 while [[ $startdate < $enddate  ]]
 do
      /opt/spark/bin/spark-submit --master spark://10.31.242.83:7077  --total-executor-cores 10 --executor-memory 3g  --executor-cores 2 --driver-memory 8g --class com.gmei.         strategy_clk_imp_oldUser /srv/apps/ffm-baseline/eda/feededa/target/scala-2.11/feededa-assembly-0.1.jar --env prod --date $startdate >> ctr2.log
     startdate=`date -d "+1 day $startdate" +%Y-%m-%d`
 done
