IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 29, 2010, 3:55:49 PM (16 years ago)
Author:
eugene
Message:

update merges from trunk

Location:
branches/eam_branches/20100225
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/20100225

  • branches/eam_branches/20100225/ippTools/src/difftool.c

    r27020 r27517  
    158158            exposure,
    159159            false,
    160             diff_mode,
     160            diff_mode,
    161161            note
    162162    );
     
    204204
    205205    // pxUpdateRun gets parameters from config->args and updates
    206     bool result = pxUpdateRun(config, where, &query, "diffRun", true);
     206    bool result = pxUpdateRun(config, where, &query, "diffRun", "diff_id", "diffSkyfile", true);
    207207
    208208    psFree(query);
     
    210210
    211211    return result;
    212 
    213 #ifdef notdef
    214     // required options
    215     PXOPT_LOOKUP_S64(diff_id, config->args, "-diff_id", false, false);
    216     PXOPT_LOOKUP_STR(state, config->args, "-state", true, false);
    217     PXOPT_LOOKUP_STR(label, config->args, "-label", false, false);
    218 
    219     // Copy of my hacky work around from stacktool.c
    220     if ((state)&&(diff_id)) {
    221         // set detRun.state to state
    222         return setdiffRunState(config, diff_id, state, false);
    223     }
    224 
    225     if ((state)&&(label)) {
    226       return setdiffRunStateByLabel(config, label, state);
    227     }
    228 
    229     psError(PS_ERR_UNKNOWN, false, "Required options not found.");
    230 
    231     return false;
    232 #endif
    233212}
    234213
     
    730709        PXOPT_COPY_TIME(config->args, where, "-dateobs_begin", "rawInput.dateobs",  ">=");
    731710        PXOPT_COPY_TIME(config->args, where, "-dateobs_end",   "rawInput.dateobs",  "<=");
    732         PXOPT_COPY_STR(config->args, where, "-filter",     "rawInput.filter", "==");
     711        PXOPT_COPY_STR(config->args, where, "-filter",     "rawInput.filter", "LIKE");
    733712    } else {
    734713        PXOPT_COPY_S64(config->args, where, "-exp_id", "rawTemplate.exp_id", "==");
     
    737716        PXOPT_COPY_TIME(config->args, where, "-dateobs_begin", "rawTemplate.dateobs",  ">=");
    738717        PXOPT_COPY_TIME(config->args, where, "-dateobs_end",   "rawTemplate.dateobs",  "<=");
    739         PXOPT_COPY_STR(config->args, where, "-filter",     "rawTemplate.filter", "==");
     718        PXOPT_COPY_STR(config->args, where, "-filter",     "rawTemplate.filter", "LIKE");
    740719    }
    741720
     
    1005984      diff_mode = 4;
    1006985    }
    1007    
    1008    
     986
     987
    1009988    // default
    1010989    PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false);
     
    10251004            false,
    10261005            0,       // magicked
    1027             diff_mode, // diff_mode
     1006            diff_mode, // diff_mode
    10281007            note
    10291008    );
     
    11651144    PXOPT_COPY_S64(config->args, expWhere, "-exp_id", "exp_id", "==");
    11661145    PXOPT_COPY_STR(config->args, expWhere, "-filter", "filter", "==");
     1146    PXOPT_COPY_STR(config->args, expWhere, "-comment", "comment", "LIKE");
    11671147    PXOPT_COPY_S64(config->args, warp1Where, "-warp_id", "warpRun.warp_id", "==");
    11681148    PXOPT_COPY_STR(config->args, warp1Where, "-warp_label", "warpRun.label", "==");
     
    14361416                true,                   // exposure
    14371417                0,       // magicked
    1438                 2,       // diff_mode for warp-stack difference
     1418                2,       // diff_mode for warp-stack difference
    14391419                note
    14401420        );
     
    15841564    // Additional controls
    15851565    PXOPT_LOOKUP_BOOL(rerun, config->args, "-rerun", false);
    1586     PXOPT_LOOKUP_BOOL(available, config->args, "-available", false);
    15871566
    15881567    // Settings to apply to defined run
     
    16771656    if (psListLength(selectWhere->list)) {
    16781657        psString new = psDBGenerateWhereConditionSQL(selectWhere, NULL);
    1679         psStringAppend(&whereClause, "\n%s %s", whereClause ? "AND" : "WHERE", new);
     1658        psStringAppend(&whereClause, "\nAND %s", new);
    16801659        psFree(new);
    16811660    }
    16821661    psFree(selectWhere);
    16831662
    1684     if (!available) {
    1685         psStringAppend(&whereClause,
    1686                        "\n%s inputWarpRun.state = 'full'"
    1687                        "AND templateWarpRun.state = 'full'",
    1688                        whereClause ? "AND" : "WHERE");
    1689     }
    1690 
    16911663    if (!rerun) {
    1692         psStringAppend(&whereClause, "\n%s diffs.diff_id IS NULL", whereClause ? "AND" : "WHERE");
     1664        psStringAppend(&whereClause, "\nAND diffs.diff_id IS NULL");
    16931665    }
    16941666
     
    17791751
    17801752        diffRunRow *run = diffRunRowAlloc(0,
    1781                                           "reg",
    1782                                           workdir,
    1783                                           label,
    1784                                           data_group ? data_group : label,
    1785                                           dist_group,
    1786                                           reduction,
    1787                                           NULL,  // dvodb
    1788                                           registered,
     1753                                          "reg",
     1754                                          workdir,
     1755                                          label,
     1756                                          data_group ? data_group : label,
     1757                                          dist_group,
     1758                                          reduction,
     1759                                          NULL,  // dvodb
     1760                                          registered,
    17891761                                          tess_id,
    1790                                           true,  // bothways
    1791                                           true,  // exposure
    1792                                           false, // magicked
    1793                                           1,     // diff_mode for warp-warp diff
    1794                                           note); // Run to insert
     1762                                          true,  // bothways
     1763                                          true,  // exposure
     1764                                          false, // magicked
     1765                                          1,     // diff_mode for warp-warp diff
     1766                                          note); // Run to insert
    17951767        if (!diffRunInsertObject(config->dbh, run)) {
    17961768            psError(PS_ERR_UNKNOWN, false, "database error");
     
    20732045                                      false,                 // exposure
    20742046                                      0,       // magicked
    2075                                       4,       // diff_mode
     2047                                      4,       // diff_mode
    20762048                                      note
    20772049                                      );
Note: See TracChangeset for help on using the changeset viewer.