Changeset 18618
- Timestamp:
- Jul 18, 2008, 12:20:51 PM (18 years ago)
- Location:
- trunk/ippTools/src
- Files:
-
- 2 edited
-
difftool.c (modified) (2 diffs)
-
difftoolConfig.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippTools/src/difftool.c
r18615 r18618 293 293 PXOPT_LOOKUP_BOOL(simple, config->args, "-simple", false); 294 294 PXOPT_LOOKUP_BOOL(template, config->args, "-template", false); 295 PXOPT_LOOKUP_BOOL(input, config->args, "-input", false); 296 297 if (template && input) { 298 // User apparently wants both, which is the default behaviour 299 template = false; 300 input = false; 301 } 295 302 296 303 // find all rawImfiles matching the default query … … 301 308 } 302 309 303 if (template) {304 // list only faulted rows305 psStringAppend(&query, " %s", "WHERE template != 0");306 } else {307 // don't list faulted rows308 psStringAppend(&query, " %s", "WHERE template = 0");309 }310 311 310 if (psListLength(where->list)) { 312 311 psString whereClause = psDBGenerateWhereConditionSQL(where, NULL); 313 psStringAppend(&query, " AND%s", whereClause);312 psStringAppend(&query, " WHERE %s", whereClause); 314 313 psFree(whereClause); 315 314 } 315 316 // Add condition to get only templates or only inputs 317 { 318 psString whereClause = NULL; 319 if (template) { 320 psStringAppend(&whereClause, " %s", " template != 0"); 321 } else if (input) { 322 psStringAppend(&whereClause, " %s", " template = 0"); 323 } 324 if (whereClause) { 325 psStringAppend(&query, " %s %s", psListLength(where->list) ? "AND" : "WHERE", whereClause); 326 } 327 psFree(whereClause); 328 } 329 316 330 psFree(where); 317 331 -
trunk/ippTools/src/difftoolConfig.c
r18561 r18618 73 73 psMetadataAddStr(inputskyfileArgs, PS_LIST_TAIL, "-tess_id", 0, "search by tess ID", NULL); 74 74 psMetadataAddStr(inputskyfileArgs, PS_LIST_TAIL, "-kind", 0, "search by kind", NULL); 75 psMetadataAddBool(inputskyfileArgs, PS_LIST_TAIL, "-template", 0, "search by subtrahend", false); 75 psMetadataAddBool(inputskyfileArgs, PS_LIST_TAIL, "-template", 0, "find only subtrahend", false); 76 psMetadataAddBool(inputskyfileArgs, PS_LIST_TAIL, "-input", 0, "find only minuend", false); 76 77 psMetadataAddU64(inputskyfileArgs, PS_LIST_TAIL, "-limit", 0, "limit result set to N items", 0); 77 78 psMetadataAddBool(inputskyfileArgs, PS_LIST_TAIL, "-simple", 0, "use the simple output format", false);
Note:
See TracChangeset
for help on using the changeset viewer.
