Changeset 18694 for trunk/DataCheck/QuickLook/SendData_Internal.sh
- Timestamp:
- 12/18/16 23:46:07 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/DataCheck/QuickLook/SendData_Internal.sh
r18672 r18694 83 83 printprocesslog "DEBUG sendquery QUERY: "$query 84 84 echo "DEBUG sendquery QUERY: "$query 85 mysql -s -u $us --password=$pw --host=$ho $db -e " $query "85 mysql $pwfile -s -u $us $pw --host=$ho $db -e " $query " 86 86 if [ "$table" == "AnalysisResultsRunLP" ] 87 87 then 88 88 query2=`echo $query | sed -e 's/AnalysisResultsRunLP/AnalysisResultsRunISDC/g'` 89 89 echo "# QUERY: "$query2 90 mysql -s -u $us --password=$pw --host=$ho factdata_cp20150811 -e " $query2 "91 fi90 mysql $pwfile -s -u $us $pw --host=$ho factdata_cp20150811 -e " $query2 " 91 fi 92 92 } 93 93 … … 132 132 mjd) timeselect="Mjd(Min(fRunStart)) AS start, Mjd(MAX(fRunStop)) AS stop, " 133 133 timeselect2=" Mjd(MIN(o.start)) AS start, Mjd(MAX(o.stop)) AS stop, " 134 break;;134 ;; 135 135 unix) timeselect="Unix_timestamp(CONVERT_TZ(Min(fRunStart), '+00:00', 'SYSTEM')) AS start, Unix_timestamp(CONVERT_TZ(Max(fRunStop), '+00:00', 'SYSTEM')) AS stop, " 136 136 timeselect2=" Unix_timestamp(CONVERT_TZ(MIN(o.start), '+00:00', 'SYSTEM')) AS start, Unix_timestamp(CONVERT_TZ(MAX(o.stop), '+00:00', 'SYSTEM')) AS stop, " 137 break;;137 ;; 138 138 *) timeselect="MIN(fRunStart) AS start, MAX(fRunStop) AS stop, " 139 139 timeselect2=" MIN(o.start) AS start, MAX(o.stop) as stop, " 140 break;;140 ;; 141 141 esac 142 142 … … 155 155 query="SELECT "$timeselect" SUM(fNumExcEvts)/SUM("$ontimeif")*3600 AS excrate, " 156 156 query=$query" ExcErr(Sum(fNumSigEvts), SUM(fNumBgEvts))/SUM("$ontimeif")*3600 AS excerr, " 157 query=$query" SUM("$ontimeif"/60.) AS ontime, " 157 158 query=$query" IF (SUM(fNumSigEvts)>10 AND SUM(fNumBgEvts)>10, LiMa(SUM(fNumSigEvts), SUM(fNumBgEvts)), IF (SUM(fNumSigEvts)-SUM(fNumBgEvts)>10, concat('(', LiMa(SUM(fNumSigEvts), SUM(fNumBgEvts)), ')'), '-')) AS significance, " 158 159 query=$query" LiMa(SUM(fNumSigEvts), SUM(fNumBgEvts)) AS significance2, " … … 179 180 #echo $query 180 181 181 printinfo | mail -s 'test internal downloading data ' - cdorner@astro.uni-wuerzburg.de -r dorner@astro.uni-wuerzburg.de $email182 printinfo | mail -s 'test internal downloading data ' -b dorner@astro.uni-wuerzburg.de -r dorner@astro.uni-wuerzburg.de $email 182 183 #printinfo 183 184
Note:
See TracChangeset
for help on using the changeset viewer.