IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 24161


Ignore:
Timestamp:
May 12, 2009, 7:46:14 PM (17 years ago)
Author:
Paul Price
Message:

With the WHEREs implemented inside the sub-select, the final WHERE was
destroying the result for the merge part (since the 'node' is set to
the dependents, not the node name).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/pap_magic/ippTools/src/magictool.c

    r24156 r24161  
    614614    psMetadata *templatesWhere = psMetadataAlloc(); // WHERE for selecting template
    615615    psMetadata *magicWhere = psMetadataAlloc();     // WHERE for selecting magic runs
    616     psMetadata *finalWhere = psMetadataAlloc();     // WHERE at end
    617616
    618617    PXOPT_COPY_S64(config->args, templatesWhere, "-magic_id", "magicRun.magic_id", "==");
     
    621620    PXOPT_COPY_S64(config->args, magicWhere, "-magic_id", "magicRun.magic_id", "==");
    622621    PXOPT_COPY_STR(config->args, magicWhere, "-node", "magicTree.node", "==");
    623 
    624     PXOPT_COPY_S64(config->args, finalWhere, "-magic_id", "magicRun.magic_id", "==");
    625     PXOPT_COPY_STR(config->args, finalWhere, "-node", "magicInputs.node", "==");
    626622
    627623    PXOPT_LOOKUP_U64(limit, config->args, "-limit", false, false);
     
    650646    }
    651647    psFree(magicWhere);
    652 
    653     if (psListLength(finalWhere->list)) {
    654         psString whereClause = psDBGenerateWhereConditionSQL(finalWhere, NULL);
    655         psStringAppend(&query, "\nWHERE %s", whereClause);
    656         psFree(whereClause);
    657     }
    658     psFree(finalWhere);
    659648
    660649    // treat limit == 0 as "no limit"
Note: See TracChangeset for help on using the changeset viewer.