IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 12, 2010, 12:06:23 PM (16 years ago)
Author:
bills
Message:

in -updatrun allow selection by dist_group and data_group

File:
1 edited

Legend:

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

    r26519 r26925  
    428428    PXOPT_COPY_S64(config->args, where, "-dist_id", "dist_id", "==");
    429429    PXOPT_COPY_STR(config->args, where, "-stage", "stage", "==");;
    430     PXOPT_COPY_STR(config->args, where, "-state", "state", "==");
     430    PXOPT_COPY_STR(config->args, where, "-state", "distRun.state", "==");
     431    PXOPT_COPY_STR(config->args, where, "-label", "label", "==");
     432    PXOPT_COPY_STR(config->args, where, "-data_group", "distRun.data_group", "==");
     433    PXOPT_COPY_STR(config->args, where, "-dist_group", "distTarget.dist_group", "==");
    431434    PXOPT_COPY_STR(config->args, where, "-label", "label", "==");
    432435
     
    448451    }
    449452
    450     psString query = psStringCopy("UPDATE distRun SET time_stamp = UTC_TIMESTAMP()");
     453    psString query = psStringCopy("UPDATE distRun join distTarget using(target_id, stage) SET distRun.time_stamp = UTC_TIMESTAMP()");
    451454
    452455    if (outdir) {
    453         psStringAppend(&query, " , outdir = '%s'", outdir);
     456        psStringAppend(&query, " , distRun.outdir = '%s'", outdir);
    454457    }
    455458    if (state) {
    456         psStringAppend(&query, " , state = '%s'", state);
     459        psStringAppend(&query, " , distRun.state = '%s'", state);
    457460    }
    458461
    459462    if (label) {
    460         psStringAppend(&query, " , label = '%s'", label);
     463        psStringAppend(&query, " , distRun.label = '%s'", label);
    461464    }
    462465
    463466    if (fault) {
    464         psStringAppend(&query, " , fault = %d", fault);
     467        psStringAppend(&query, " , distRun.fault = %d", fault);
    465468    }
    466469
Note: See TracChangeset for help on using the changeset viewer.