Changeset 30638
- Timestamp:
- Feb 14, 2011, 4:17:01 PM (15 years ago)
- File:
-
- 1 edited
-
trunk/tools/examine_burntool_pcontrol.pl (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/examine_burntool_pcontrol.pl
r28886 r30638 145 145 # Get the data. The limit is there to keep the database happy. I don't think you can observe that many 146 146 # images on a single night. 147 $sth = "SELECT exp_id, exp_name,obs_mode,dateobs,class_id,burntool_state,comment FROM rawImfile WHERE dateobs >= '${dmin}' AND dateobs <= '${dmax}' order bydateobs limit 600000";147 $sth = "SELECT exp_id,rawImfile.exp_name,rawImfile.obs_mode,rawImfile.dateobs,class_id,burntool_state,rawImfile.comment,rawExp.state FROM rawImfile JOIN rawExp USING(exp_id) WHERE rawImfile.dateobs >= '${dmin}' AND rawImfile.dateobs <= '${dmax}' order by rawImfile.dateobs limit 600000"; 148 148 149 149 $data_ref = $db->selectall_arrayref( $sth ); … … 168 168 } 169 169 print "# 0 1 2 3 4 5 6 7 \n"; 170 print "#exp_i exp_name obs_mode dateobs nB 0123456701234567012345670123456701234567012345670123456701234567 comment\n";170 print "#exp_i exp_name obs_mode dateobs nB 0123456701234567012345670123456701234567012345670123456701234567 rawExp.state comment\n"; 171 171 172 172 # If the database returns no entries (because we have a mistake in pcontrol.pro perhaps), return a null entry. … … 180 180 181 181 foreach $row_ref (@{ $data_ref }) { 182 ($exp_id,$exp_name, $obs_mode,$dateobs,$class_id,$burntool_state,$comment ) = @{ $row_ref };182 ($exp_id,$exp_name, $obs_mode,$dateobs,$class_id,$burntool_state,$comment,$exp_state) = @{ $row_ref }; 183 183 184 184 # Correct for nulls in the database. … … 202 202 203 203 if ($cur_exp_id != -99) { 204 printf("%6d %11s %11s %19s %2d %64s % s\n",205 $cur_exp_id,$cur_exp_name,$cur_obs_mode,$cur_dateobs,$burncount, $V,$cur_ comment);204 printf("%6d %11s %11s %19s %2d %64s %15s %s\n", 205 $cur_exp_id,$cur_exp_name,$cur_obs_mode,$cur_dateobs,$burncount, $V,$cur_exp_state,$cur_comment); 206 206 207 207 if (($burncount != 60)&&(exists($opt{A}))) { … … 228 228 } 229 229 ($cur_exp_id,$cur_exp_name,$cur_obs_mode,$cur_dateobs,$cur_comment) = ($exp_id,$exp_name,$obs_mode,$dateobs,$comment); 230 $cur_exp_state = $exp_state; 230 231 class_to_vector($class_id,$burntool_state); 231 232 } 232 233 } 233 234 # Final entry needs a manual print to clear it out. Let's tack on a footer as well. 234 printf("%6d %11s %11s %19s %2d %64s % s\n",235 $cur_exp_id,$cur_exp_name,$cur_obs_mode,$cur_dateobs,$burncount, $V,$cur_ comment);235 printf("%6d %11s %11s %19s %2d %64s %15s %s\n", 236 $cur_exp_id,$cur_exp_name,$cur_obs_mode,$cur_dateobs,$burncount, $V,$cur_exp_state,$cur_comment); 236 237 print "# 0 1 2 3 4 5 6 7 \n"; 237 print "#exp_i exp_name obs_mode dateobs nB 0123456701234567012345670123456701234567012345670123456701234567 comment\n";238 print "#exp_i exp_name obs_mode dateobs nB 0123456701234567012345670123456701234567012345670123456701234567 rawExp.state comment\n"; 238 239 print"\n"; 239 240
Note:
See TracChangeset
for help on using the changeset viewer.
