IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 25, 2006, 12:39:50 PM (20 years ago)
Author:
jhoblitt
Message:

fix -addresidimfile also handle detStackedImfile.normalize = 0

File:
1 edited

Legend:

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

    r8590 r8606  
    25582558    // where det_id, iteration, class_id is not in detResidImfile
    25592559    psString query = psStringCopy(
    2560         "SELECT"
    2561         "   detNormalizedImfile.*"
     2560        "SELECT * FROM"
     2561        " (SELECT"
     2562        "   detNormalizedImfile.det_id,"
     2563        "   detNormalizedImfile.iteration,"
     2564        "   detNormalizedImfile.class_id,"
     2565        "   detNormalizedImfile.uri"
    25622566        " FROM detNormalizedImfile"
    2563         " LEFT JOIN detInputExp"
     2567        " JOIN detInputExp"
    25642568        "   USING(det_id, iteration)"
    25652569        " LEFT JOIN detResidImfile"
     
    25692573        "   AND detNormalizedImfile.class_id = detResidImfile.class_id"
    25702574        " WHERE"
    2571         "  detInputExp.exp_id = '%s'"
    2572         "  AND detResidImfile.det_id IS NULL"
     2575        "  detResidImfile.det_id IS NULL"
    25732576        "  AND detResidImfile.iteration IS NULL"
    25742577        "  AND detResidImfile.exp_id IS NULL"
    25752578        "  AND detResidImfile.class_id IS NULL"
     2579        "  AND detInputExp.exp_id = '%s'"
     2580        " UNION"
     2581        " SELECT"
     2582        "   detStackedImfile.det_id,"
     2583        "   detStackedImfile.iteration,"
     2584        "   detStackedImfile.class_id,"
     2585        "   detStackedImfile.uri"
     2586        " FROM detStackedImfile"
     2587        " JOIN detInputExp"
     2588        "   USING(det_id, iteration)"
     2589        " LEFT JOIN detResidImfile"
     2590        "   ON detStackedImfile.det_id = detResidImfile.det_id"
     2591        "   AND detStackedImfile.iteration= detResidImfile.iteration"
     2592        "   AND detInputExp.exp_id = detResidImfile.exp_id"
     2593        "   AND detStackedImfile.class_id = detResidImfile.class_id"
     2594        " WHERE"
     2595        "   detResidImfile.det_id IS NULL" 
     2596        "   AND detResidImfile.iteration IS NULL" 
     2597        "   AND detResidImfile.exp_id IS NULL" 
     2598        "   AND detResidImfile.class_id IS NULL" 
     2599        "   AND detInputExp.exp_id = '%s'"
     2600        "   AND detStackedImfile.normalize = 0"
     2601        " ) as detNormStackedImfile"
    25762602        );
    25772603
     
    26262652
    26272653        // there's not
    2628         psString whereClause = psDBGenerateWhereConditionSQL(where, "detNormalizedImfile");
     2654        psString whereClause = psDBGenerateWhereSQL(where, NULL);
    26292655        psFree(where);
    26302656        if (whereClause) {
    2631             psStringAppend(&query, " AND %s", whereClause);
     2657            psStringAppend(&query, " %s", whereClause);
    26322658            psFree(whereClause);
    26332659        }
Note: See TracChangeset for help on using the changeset viewer.