Changeset 34265
- Timestamp:
- Jul 31, 2012, 4:55:25 PM (14 years ago)
- Location:
- trunk
- Files:
-
- 6 added
- 7 edited
-
ippScripts/scripts/addstar_run.pl (modified) (4 diffs)
-
ippTasks/addstar.pro (modified) (9 diffs)
-
ippTasks/survey.pro (modified) (1 diff)
-
ippTools/share/Makefile.am (modified) (3 diffs)
-
ippTools/share/addtool_find_pendingexp_skycal.sql (added)
-
ippTools/share/addtool_find_processedexp_skycal.sql (added)
-
ippTools/share/addtool_find_skycal_id.sql (added)
-
ippTools/share/addtool_find_skycal_id_dvo.sql (added)
-
ippTools/share/addtool_queue_skycal_id.sql (added)
-
ippTools/share/addtool_revertprocessedexp_skycal.sql (added)
-
ippTools/src/addtool.c (modified) (14 diffs)
-
ippTools/src/addtoolConfig.c (modified) (3 diffs)
-
ippTools/src/pxadd.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/addstar_run.pl
r34080 r34265 94 94 # Recipes to use based on reduction class 95 95 $reduction = 'DEFAULT' unless defined $reduction; 96 if ($stage =~/skycal/) { 97 $reduction = 'DEFAULT'; 98 } 96 99 my $recipe_addstar = $ipprc->reduction($reduction, 'ADDSTAR'); 97 100 # XXX This is now not used: do we still need it? … … 105 108 # $recipe_addstar = $ipprc->reduction($reduction, 'ADDSTAR_STATICSKY'); # Recipe to use 106 109 #} 110 if ($stage =~/skycal/) { 111 $recipe_addstar = $ipprc->reduction($reduction, 'ADDSTAR'); # Recipe to use 112 } 113 114 115 107 116 &my_die("Unrecognised ADDSTAR recipe", $add_id, $PS_EXIT_CONFIG_ERROR) unless defined $recipe_addstar; 108 117 … … 118 127 my $fpaObjects = $ipprc->filename("PSASTRO.OUTPUT", $stageroot) or &my_die("Missing entry from camera config", $add_id, $PS_EXIT_CONFIG_ERROR); 119 128 my $fpaObjectsAlt = $fpaObjects; 129 130 if ($stage =~ /skycal/) { 131 #should be ok for skycal? 132 print "using $fpaObjects for $stage\n"; 133 } 120 134 121 135 … … 162 176 } 163 177 } 164 if (($stage =~/stack/)) { 178 179 if (($stage =~/stack/ || $stage =~ /skycal/)) { 165 180 $fpaObjects =~ s/smf$/cmf/; 166 181 $fpaObjectsAlt =~ s/smf$/cmf/; 167 182 168 183 } 184 169 185 my $fpaObjects1; 170 186 my $fpaObjects2; -
trunk/ippTasks/addstar.pro
r33989 r34265 24 24 end 25 25 task addstar.exp.load.staticsky 26 active true 27 end 28 task addstar.exp.load.skycal 26 29 active true 27 30 end … … 41 44 active false 42 45 end 46 task addstar.exp.load.skycal 47 active false 48 end 43 49 task addstar.exp.run 44 50 active false … … 50 56 active false 51 57 end 52 task addstar.revert.stack 53 active false 54 end 55 task addstar.revert.staticsky 56 active false 57 end 58 end 58 task addstar.revert.stack 59 active false 60 end 61 task addstar.revert.staticsky 62 active false 63 end 64 task addstar.revert.skycal 65 active false 66 end 67 end 68 59 69 macro addstar.revert.on 60 70 task addstar.revert.cam … … 65 75 end 66 76 task addstar.revert.staticsky 77 active true 78 end 79 task addstar.revert.skycal 67 80 active true 68 81 end … … 77 90 $addstar_revert_DB_SS = 0 78 91 $addstar_revert_DB_SSM = 0 92 $addstar_revert_DB_SC = 0 79 93 80 94 $LOADEXEX_ADD = 300 … … 244 258 245 259 # operation times out? 260 task.exit timeout 261 showcommand timeout 262 end 263 end 264 265 task addstar.exp.load.skycal 266 host local 267 periods -poll $LOADPOLL 268 periods -exec 300 269 periods -timeout 300 270 npending 1 271 272 stdout NULL 273 stderr $LOGDIR/addstar.exp.log 274 275 task.exec 276 # if ($LABEL:n == 0) break 277 $run = addtool -pendingexp -stage skycal 278 if ($DB:n == 0) 279 option DEFAULT 280 else 281 # save the DB name for the exit tasks 282 option $DB:$addstar_DB 283 $run = $run -dbname $DB:$addstar_DB 284 $addstar_DB ++ 285 if ($addstar_DB >= $DB:n) set addstar_DB = 0 286 end 287 add_poll_args run 288 add_poll_labels run 289 command $run 290 end 291 292 # success 293 task.exit 0 294 # convert 'stdout' to book format 295 ipptool2book stdout addPendingExp -key add_id -uniq -setword dbname $options:0 -setword pantaskState INIT 296 if ($VERBOSE > 2) 297 book listbook addPendingExp 298 end 299 300 # delete existing entries in the appropriate pantaskStates 301 process_cleanup addPendingExp 302 end 303 304 # default exit status 305 task.exit default 306 showcommand failure 307 end 308 309 task.exit crash 310 showcommand crash 311 end 312 313 # operation times out? 246 314 task.exit timeout 247 315 showcommand timeout … … 311 379 sprintf outroot "%s.add.%s" $STAGEROOT $ADD_ID 312 380 end 381 if ("$STAGE" == "skycal") 382 sprintf outroot "%s.add.%s" $STAGEROOT $ADD_ID 383 end 384 313 385 314 386 … … 326 398 $run = $run --stage_id $STAGE_ID 327 399 end 400 if ("$STAGE" == "skycal") 401 $run = $run --stage_id $STAGE_ID 402 end 403 404 405 328 406 if ("$IMAGE_ONLY" == "T") 329 407 $run = $run --image-only … … 508 586 end 509 587 end 588 589 task addstar.revert.skycal 590 host local 591 592 periods -poll 5.0 593 periods -exec 60.0 594 periods -timeout 1200 595 npending 1 596 active false 597 598 stdout NULL 599 stderr $LOGDIR/revert.log 600 601 task.exec 602 if ($LABEL:n == 0) break 603 $run = addtool -revertprocessedexp -stage skycal 604 if ($DB:n == 0) 605 option DEFAULT 606 else 607 # save the DB name for the exit tasks 608 option $DB:$addstar_revert_DB_SC 609 $run = $run -dbname $DB:$addstar_revert_DB_SC 610 $addstar_revert_DB_SC ++ 611 if ($addstar_revert_DB_SC >= $DB:n) set addstar_revert_DB_SC = 0 612 end 613 add_poll_labels run 614 command $run 615 end 616 617 # success 618 task.exit 0 619 end 620 621 # locked list 622 task.exit default 623 showcommand failure 624 end 625 626 task.exit crash 627 showcommand crash 628 end 629 630 # operation times out? 631 task.exit timeout 632 showcommand timeout 633 end 634 end -
trunk/ippTasks/survey.pro
r33525 r34265 862 862 #only queue uncensored stacks 863 863 $run = $run -uncensored 864 end 865 if ("$stage" == "skycal") 866 #skycal doesn't have magic, however, we still need to tell addtool 867 $run = $run -uncensored 864 868 end 865 869 -
trunk/ippTools/share/Makefile.am
r33744 r34265 8 8 addtool_find_cam_id_dvo.sql \ 9 9 addtool_find_cam_id.sql \ 10 addtool_find_skycal_id_dvo.sql \ 11 addtool_find_skycal_id.sql \ 10 12 addtool_find_sky_id_multi_dvo.sql \ 11 13 addtool_find_sky_id_multi.sql \ … … 14 16 addtool_find_pendingexp.sql \ 15 17 addtool_find_pendingexp_cam.sql \ 18 addtool_find_pendingexp_skycal.sql \ 16 19 addtool_find_pendingexp_stack.sql \ 17 20 addtool_find_pendingexp_staticsky_multi.sql \ 18 21 addtool_find_pendingmergeprocess.sql \ 19 22 addtool_find_processedexp_cam.sql \ 23 addtool_find_processedexp_skycal.sql \ 20 24 addtool_find_processedexp_stack.sql \ 21 25 addtool_find_processedexp_staticsky_multi.sql \ … … 27 31 addtool_queue_stack_id.sql \ 28 32 addtool_queue_sky_id_multi.sql \ 33 addtool_queue_skycal_id.sql \ 29 34 addtool_queue_minidvodbrun.sql \ 30 35 addtool_revertminidvodbprocessed.sql \ 31 36 addtool_revertprocessedexp_cam.sql \ 37 addtool_revertprocessedexp_skycal.sql \ 32 38 addtool_revertprocessedexp_stack.sql \ 33 39 addtool_revertprocessedexp_staticsky.sql \ -
trunk/ippTools/src/addtool.c
r34081 r34265 120 120 PXOPT_COPY_S64(config->args, where, "-cam_id", "camRun.cam_id", "=="); 121 121 PXOPT_COPY_S64(config->args, where, "-stack_id", "stackRun.stack_id", "=="); 122 PXOPT_COPY_S64(config->args, where, "-sky_id", "staticskyRun.sky_id", "=="); 122 PXOPT_COPY_S64(config->args, where, "-sky_id", "staticskyRun.sky_id", "=="); 123 PXOPT_COPY_S64(config->args, where, "-skycal_id", "skycalRun.skycal_id", "=="); 123 124 PXOPT_LOOKUP_STR(stage, config->args, "-stage", false, false); 124 125 if (strcmp(stage, "cam")== 0) { 125 126 pxcamGetSearchArgs (config, where); 126 pxAddLabelSearchArgs (config, where, "-label", "camRun.label", "=="); // define using camRun label 127 pxAddLabelSearchArgs (config, where, "-data_group","camRun.data_group", "=="); // define using camRun label 128 129 PXOPT_COPY_STR(config->args, where, "-reduction", "camRun.reduction", "=="); 127 pxAddLabelSearchArgs (config, where, "-label", "camRun.label", "=="); // define using camRun label 128 pxAddLabelSearchArgs (config, where, "-data_group","camRun.data_group", "=="); // define using camRun label 129 PXOPT_COPY_STR(config->args, where, "-reduction", "camRun.reduction", "=="); 130 130 } 131 131 if (strcmp(stage, "stack")== 0) { 132 133 pxAddLabelSearchArgs (config, where, "-label", "stackRun.label", "=="); // define using camRun label 134 pxAddLabelSearchArgs (config, where, "-data_group","stackRun.data_group", "=="); // define using camRun label 135 PXOPT_COPY_STR(config->args, where, "-reduction", "stackRun.reduction", "=="); 136 pxAddLabelSearchArgs (config, where, "-filter", "stackRun.filter", "=="); // define using camRun label 132 pxAddLabelSearchArgs (config, where, "-label", "stackRun.label", "=="); // define using camRun label 133 pxAddLabelSearchArgs (config, where, "-data_group","stackRun.data_group", "=="); // define using camRun label 134 PXOPT_COPY_STR(config->args, where, "-reduction", "stackRun.reduction", "=="); 135 pxAddLabelSearchArgs (config, where, "-filter", "stackRun.filter", "=="); // define using camRun label 137 136 } 138 137 if (strcmp(stage, "staticsky")== 0) { 139 140 pxAddLabelSearchArgs (config, where, "-label", "staticskyRun.label", "=="); // define using camRun label 141 pxAddLabelSearchArgs (config, where, "-data_group","staticskyRun.data_group", "=="); // define using camRun label 142 PXOPT_COPY_STR(config->args, where, "-reduction", "staticskyyRun.reduction", "=="); 138 pxAddLabelSearchArgs (config, where, "-label", "staticskyRun.label", "=="); // define using camRun label 139 pxAddLabelSearchArgs (config, where, "-data_group","staticskyRun.data_group", "=="); // define using camRun label 140 PXOPT_COPY_STR(config->args, where, "-reduction", "staticskyRun.reduction", "=="); 143 141 //no filter here 144 142 } 143 if (strcmp(stage, "skycal")==0) { 144 pxAddLabelSearchArgs (config, where, "-label", "skycalRun.label", "=="); //define using skycalRun label 145 pxAddLabelSearchArgs (config, where, "-data_group","skycalRun.data_group", "=="); 146 PXOPT_COPY_STR(config->args, where, "-reduction", "skycalRun.reduction", "=="); 147 } 148 145 149 if (!psListLength(where->list)) { 146 150 psFree(where); … … 228 232 // user supplied dvodb 229 233 psStringAppend(&dvodb_string, "addRun.dvodb = '%s'", dvodb); 230 } else {231 psTrace("addtool.c", PS_LOG_INFO, "dvodb argument not found using addtool_find_sky_id_multi.sql\n%s\n",stage);234 } else { 235 psTrace("addtool.c", PS_LOG_INFO, "dvodb argument not found using addtool_find_sky_id_multi.sql\n%s\n",stage); 232 236 // find the cam_id of all the exposures that we want to queue up. 233 237 bare_query = pxDataGet("addtool_find_sky_id_multi.sql"); 234 238 // inherit dvodb from camRun, avoid matching NULL 235 239 psStringAppend(&dvodb_string, "(staticskyRun.dvodb IS NOT NULL AND previous_dvodb = staticskyRun.dvodb)"); 236 } 237 } 240 } 241 } 242 243 if (strcmp(stage,"skycal") == 0) { 244 if (dvodb ) { 245 psTrace("addtool.c", PS_LOG_INFO, "dvodb argument found (%s) using addtool_find_skycal_id_dvo.sql\n%s\n", dvodb,stage); 246 // find the skycal_id of all the exposures that we want to queue up. 247 bare_query = pxDataGet("addtool_find_skycal_id_dvo.sql"); 248 // user supplied dvodb 249 psStringAppend(&dvodb_string, "addRun.dvodb = '%s'", dvodb); 250 } else { 251 psTrace("addtool.c", PS_LOG_INFO, "dvodb argument not found using addtool_find_skycal_id.sql\n%s\n",stage); 252 // find the skycal_id of all the exposures that we want to queue up. 253 bare_query = pxDataGet("addtool_find_skycal_id.sql"); 254 // inherit dvodb from skycalRun, avoid matching NULL 255 psStringAppend(&dvodb_string, "(skycalRun.dvodb IS NOT NULL AND previous_dvodb = skycalRun.dvodb)"); 256 // this is silly, there is no dvodb in skycalRun...? 257 } 258 } 259 260 261 262 263 264 238 265 239 266 if (!bare_query) { … … 267 294 psStringAppend(&query, " AND (stackRun.magicked > 0)"); 268 295 } 269 // staticSky hasno magicked column.296 // staticSky/skycal have no magicked column. 270 297 } else { 271 298 //This picks only the unmagicked/uncensored ones … … 291 318 // psStringAppend(&query, " GROUP BY stack_id"); 292 319 // } 293 if (strcmp(stage,"staticsky") == 0) { 294 psStringAppend(&query, " GROUP BY sky_id, stack_id"); //some reason it needs this 295 } 296 320 if (strcmp(stage,"staticsky") == 0) { 321 psStringAppend(&query, " GROUP BY sky_id, stack_id"); //some reason it needs this 322 } 323 if (strcmp(stage,"skycal") == 0) { 324 psStringAppend(&query, " GROUP BY skycal_id, sky_id, stack_id "); //this needs checking, but I think it shoul be fine? it groups by lots of stuff (including stack - we only want one of each stack in there 325 } 297 326 298 327 psTrace("addtool.c", PS_LOG_INFO,"query: \n\n%s\n\n",query); … … 381 410 } 382 411 412 413 383 414 if (strcmp(stage,"staticsky") == 0) { 384 415 for (long i = 0; i < psArrayLength(output); i++) { … … 418 449 } 419 450 451 if (strcmp(stage,"skycal") == 0) { 452 for (long i = 0; i < psArrayLength(output); i++) { 453 psMetadata *md = output->data[i]; 454 455 skycalRunRow *row = skycalRunObjectFromMetadata(md); 456 457 if (!row) { 458 psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into skycalRun"); 459 psFree(output); 460 return false; 461 } 462 463 if (!dvodb) { // there's no skycalRun.dvodb 464 psError(PS_ERR_UNKNOWN, false, "cannot queue addstar run without a defined dvodb: label: %s, skycal_id %" PRId64, row->label, row->skycal_id); 465 psFree(output); 466 return false; 467 } 468 if (!workdir && !row->workdir) { 469 psError(PS_ERR_UNKNOWN, false, "cannot queue addstar run without a defined workdir: label: %s, skycal_id %" PRId64, row->label, row->skycal_id); 470 psFree(output); 471 return false; 472 } 473 474 psFree(row); 475 } 476 } 420 477 421 478 … … 572 629 } 573 630 574 631 if (strcmp(stage,"skycal") == 0) { 632 for (long i = 0; i < psArrayLength(output); i++) { 633 psMetadata *md = output->data[i]; 634 psS64 stage_id =0; 635 636 skycalRunRow *row = skycalRunObjectFromMetadata(md); 637 stage_id = row->skycal_id; 638 639 if (!row) { 640 psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into skycalRun"); 641 psFree(output); 642 return false; 643 } 644 645 // queue the exp 646 if (!pxaddQueueByCamID(config, 647 stage, 648 stage_id, 649 0, 650 workdir ? workdir : row->workdir, 651 reduction ? reduction : row->reduction, 652 label ? label : row->label, 653 data_group ? data_group : (row->data_group ? row->data_group : (label ? label : row->label)), 654 dvodb ? dvodb : NULL, 655 note ? note : NULL, 656 image_only, 657 minidvodb, 658 minidvodb_group, 659 minidvodb_name 660 )) { 661 if (!psDBRollback(config->dbh)) { 662 psError(PS_ERR_UNKNOWN, false, "database error sfg"); 663 } 664 psError(PS_ERR_UNKNOWN, false, 665 "failed to trying to queue stage %s %" PRId64,stage, stage_id); 666 psFree(row); 667 psFree(output); 668 return false; 669 } 670 psFree(row); 671 } 672 } 673 575 674 576 675 … … 594 693 PXOPT_COPY_S64(config->args, where, "-cam_id", "camRun.cam_id", "=="); 595 694 PXOPT_COPY_S64(config->args, where, "-stack_id", "stackRun.stack_id", "=="); 596 PXOPT_COPY_S64(config->args, where, "-sky_id", "staticskyRun.sky_id", "==");597 695 PXOPT_COPY_S64(config->args, where, "-sky_id", "staticskyRun.sky_id", "=="); 696 PXOPT_COPY_S64(config->args, where, "-skycal_id", "skycalRun.skycal_id", "=="); 598 697 PXOPT_LOOKUP_STR(stage, config->args, "-stage", false, false); 599 698 pxcamGetSearchArgs (config, where); // most search arguments based on camera … … 610 709 psString query = NULL; 611 710 if (strcmp(stage, "cam")==0) { 612 query = psStringCopy("UPDATE addRun JOIN camRun on cam_id = stage_id JOIN chipRun USING(chip_id) JOIN rawExp USING(exp_id)");711 query = psStringCopy("UPDATE addRun JOIN camRun on cam_id = stage_id JOIN chipRun USING(chip_id) JOIN rawExp USING(exp_id)"); 613 712 } 614 713 if (strcmp(stage, "stack")==0) { 615 query = psStringCopy("UPDATE addRun JOIN stackRun on stack_id = stage_id");714 query = psStringCopy("UPDATE addRun JOIN stackRun on stack_id = stage_id"); 616 715 } 617 716 if (strcmp(stage, "staticsky")==0) { 618 query = psStringCopy("UPDATE addRun JOIN staticskyRun on sky_id = stage_id"); 619 } 620 717 query = psStringCopy("UPDATE addRun JOIN staticskyRun on sky_id = stage_id"); 718 } 719 if (strcmp(stage, "skycal")==0) { 720 query = psStringCopy("UPDATE addRun JOIN skycalRun on skycal_id = stage_id"); 721 } 722 621 723 622 724 // pxUpdateRun gets parameters from config->args and runs the update query … … 640 742 PXOPT_COPY_S64(config->args, where, "-stack_id", "stackRun.stack_id", "=="); 641 743 PXOPT_COPY_S64(config->args, where, "-sky_id", "staticskyRun.sky_id", "=="); 744 PXOPT_COPY_S64(config->args, where, "-skycal_id", "skycalRun.skycal_id", "=="); 642 745 PXOPT_LOOKUP_STR(stage, config->args, "-stage", false, false); 643 746 pxcamGetSearchArgs (config, where); … … 650 753 651 754 if (strcmp(stage, "cam")==0) { 652 query = pxDataGet("addtool_find_pendingexp_cam.sql");755 query = pxDataGet("addtool_find_pendingexp_cam.sql"); 653 756 } 654 757 if (strcmp(stage, "stack")==0) { 655 query = pxDataGet("addtool_find_pendingexp_stack.sql");758 query = pxDataGet("addtool_find_pendingexp_stack.sql"); 656 759 } 657 760 if (strcmp(stage, "staticsky")==0) { 658 query = pxDataGet("addtool_find_pendingexp_staticsky_multi.sql"); 659 } 660 761 query = pxDataGet("addtool_find_pendingexp_staticsky_multi.sql"); 762 } 763 if (strcmp(stage, "skycal")==0) { 764 query = pxDataGet("addtool_find_pendingexp_skycal.sql"); 765 } 766 661 767 662 768 if (!query) { … … 676 782 psStringAppend(&query, " GROUP BY %s", "stack_id"); 677 783 } 678 //if (strcmp(stage, "staticsky") == 0) {679 ////this group by is needed to join against all the warps (to get camera)680 // psStringAppend(&query, " GROUP BY %s", "sky_id");681 //}784 if (strcmp(stage, "skycal") == 0) { 785 //this group by is needed to join against all the warps (to get camera) 786 psStringAppend(&query, " GROUP BY %s", "skycal_id"); 787 } 682 788 if (strcmp(stage, "staticsky") == 0) { 683 789 //this group by is needed to join against all the warps (to get camera) … … 881 987 882 988 if (strcmp (stage,"cam") == 0) { 883 query = pxDataGet("addtool_find_processedexp_cam.sql");989 query = pxDataGet("addtool_find_processedexp_cam.sql"); 884 990 } 885 991 if (strcmp (stage,"stack") == 0) { 886 query = pxDataGet("addtool_find_processedexp_stack.sql");992 query = pxDataGet("addtool_find_processedexp_stack.sql"); 887 993 } 888 994 if (strcmp (stage,"staticsky") == 0) { 889 query = pxDataGet("addtool_find_processedexp_staticsky_multi.sql"); 995 query = pxDataGet("addtool_find_processedexp_staticsky_multi.sql"); 996 } 997 if (strcmp (stage,"skycal") == 0) { 998 query = pxDataGet("addtool_find_processedexp_skycal.sql"); 890 999 } 891 1000 … … 1000 1109 query = pxDataGet("addtool_revertprocessedexp_staticsky_multi.sql"); 1001 1110 } 1111 if (strcmp(stage, "skycal") == 0) { 1112 query = pxDataGet("addtool_revertprocessedexp_skycal.sql"); 1113 } 1002 1114 1003 1115 -
trunk/ippTools/src/addtoolConfig.c
r33030 r34265 53 53 psMetadataAddS64(definebyqueryArgs, PS_LIST_TAIL, "-stack_id", 0, "search by stack_id", 0); 54 54 psMetadataAddS64(definebyqueryArgs, PS_LIST_TAIL, "-sky_id", 0, "search by sky_id", 0); 55 psMetadataAddS64(definebyqueryArgs, PS_LIST_TAIL, "-skycal_id", 0, "search by skycal_id", 0); 55 56 pxcamSetSearchArgs(definebyqueryArgs); 56 57 psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-label", PS_META_DUPLICATE_OK, "search by camRun label", NULL); … … 81 82 psMetadataAddS64(updaterunArgs, PS_LIST_TAIL, "-stack_id", 0, "search by stack_id", 0); 82 83 psMetadataAddS64(updaterunArgs, PS_LIST_TAIL, "-sky_id", 0, "search by sky_id", 0); 84 psMetadataAddS64(updaterunArgs, PS_LIST_TAIL, "-skycal_id", 0, "search by skycal_id", 0); 83 85 pxcamSetSearchArgs(updaterunArgs); 84 86 psMetadataAddStr(updaterunArgs, PS_LIST_TAIL, "-label", 0, "search by addRun label", NULL); … … 101 103 psMetadataAddS64(pendingexpArgs, PS_LIST_TAIL, "-stack_id", 0, "search by stack_id", 0); 102 104 psMetadataAddS64(pendingexpArgs, PS_LIST_TAIL, "-sky_id", 0, "search by sky_id", 0); 105 psMetadataAddS64(pendingexpArgs, PS_LIST_TAIL, "-skycal_id", 0, "search by skycal_id", 0); 103 106 pxcamSetSearchArgs(pendingexpArgs); 104 107 psMetadataAddStr(pendingexpArgs, PS_LIST_TAIL, "-label", PS_META_DUPLICATE_OK, "search by addRun label", NULL); -
trunk/ippTools/src/pxadd.c
r33525 r34265 151 151 query = pxDataGet("addtool_queue_cam_id.sql"); 152 152 psMemSetPersistent(query, true); 153 } 154 else if (strcmp(stage,"stack") == 0) { 155 query = pxDataGet("addtool_queue_stack_id.sql"); 156 psMemSetPersistent(query, true); 153 157 } 154 if (strcmp(stage,"stack") == 0) { 155 query = pxDataGet("addtool_queue_stack_id.sql"); 158 else if (strcmp(stage,"staticsky") == 0) { 159 query = pxDataGet("addtool_queue_sky_id_multi.sql"); 160 psMemSetPersistent(query, true); 161 } 162 else if (strcmp(stage,"skycal") == 0) { 163 query = pxDataGet("addtool_queue_skycal_id.sql"); 156 164 psMemSetPersistent(query, true); 157 165 } 158 if (strcmp(stage,"staticsky") == 0) { 159 query = pxDataGet("addtool_queue_sky_id_multi.sql"); 160 psMemSetPersistent(query, true); 166 else 167 { 168 psError(PXTOOLS_ERR_SYS, false, "uknown stage %s for pxadd.c", stage); 169 return false; 170 } 171 172 if (!query) { 173 psError(PXTOOLS_ERR_SYS, false, "failed to retreive SQL statement"); 174 return false; 161 175 } 162 if (!query) {163 psError(PXTOOLS_ERR_SYS, false, "failed to retreive SQL statement");164 return false;165 }166 176 } 167 177
Note:
See TracChangeset
for help on using the changeset viewer.
