Ignore:
Timestamp:
1999-07-07T18:13:10+12:00 (25 years ago)
Author:
rjmcnab
Message:

Added ability to combine two independant queries.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/src/recpt/querytools.cpp

    r270 r349  
    1212/*
    1313   $Log$
     14   Revision 1.2  1999/07/07 06:12:21  rjmcnab
     15   Added ability to combine two independant queries.
     16
    1417   Revision 1.1  1999/06/15 02:24:06  sjboddie
    1518   moved do_query from queryaction to new querytools module (as do_action
     
    7881  }
    7982
     83  // fill in the second query if needed
     84  if (!args["cq2"].empty()) {
     85    option.name = "CombineQuery";
     86    option.value = args["cq2"];
     87    request.filterOptions.push_back (option);
     88   
     89    text_t quotedstring2;
     90    text_t formattedstring2 = args["q2"];
     91    format_querystring (formattedstring2, quotedstring2);
     92
     93    option.name = "Term";
     94    option.value = formattedstring2;
     95    request.filterOptions.push_back (option);
     96
     97    option.name = "QueryType";
     98    option.value = (args.getintarg("t")) ? "ranked" : "boolean";
     99    request.filterOptions.push_back (option);
     100
     101    option.name = "Casefold";
     102    option.value = (args.getintarg("k")) ? "true" : "false";
     103    request.filterOptions.push_back (option);
     104
     105    option.name = "Stem";
     106    option.value = (args.getintarg("s")) ? "true" : "false";
     107    request.filterOptions.push_back (option);
     108
     109    if (!args["h2"].empty()) {
     110      option.name = "Index";
     111      option.value = args["h2"];
     112      request.filterOptions.push_back (option);
     113    }
     114
     115    if (!args["j2"].empty()) {
     116      option.name = "Subcollection";
     117      option.value = args["j2"];
     118      request.filterOptions.push_back (option);
     119    }
     120
     121    if (!args["n2"].empty()) {
     122      option.name = "Language";
     123      option.value = args["n2"];
     124      request.filterOptions.push_back (option);
     125    }
     126  }
     127 
    80128  option.name = "StartResults";
    81129  option.value = args["r"];
Note: See TracChangeset for help on using the changeset viewer.