IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 22, 2011, 2:29:09 PM (15 years ago)
Author:
bills
Message:

Change staticskytool -definebyquery to only queue a run if an existing run for the stacks with
given label and data_group does not exist. This allows it to work properly for single filter
staticskyRuns for nightly stacks and to support use in a survey task. Add a -rerun flag to override
that restriction

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippTools/src/staticskytool.c

    r31293 r31681  
    128128    PXOPT_LOOKUP_BOOL(pretend, config->args, "-pretend", false);
    129129    PXOPT_LOOKUP_BOOL(check_inputs, config->args, "-check_inputs", false);
     130    PXOPT_LOOKUP_BOOL(rerun, config->args, "-rerun", false);
    130131
    131132    psString select = pxDataGet("staticskytool_definebyquery_select.sql");
     
    149150    psFree(whereMD);
    150151
    151     if (!p_psDBRunQueryF(config->dbh, select, where, num_filter)) {
     152    psString make_unique = NULL;
     153    if (!rerun) {
     154        psStringAppend(&make_unique, "\nAND sky_id IS NULL");
     155    }
     156
     157    if (!p_psDBRunQueryF(config->dbh, select, where, where, num_filter, make_unique ? make_unique : "")) {
    152158        psError(PS_ERR_UNKNOWN, false, "database error");
    153159        psFree(select);
     
    155161    }
    156162    psFree(select);
     163    psFree(make_unique);
    157164
    158165    // we now have a list of (tess_id, skycell_id) that (potentially) meet out needs
Note: See TracChangeset for help on using the changeset viewer.