Merge branch 'master' into protocol-version2
authorDennis Schafroth <dennis@indexdata.com>
Tue, 15 May 2012 10:46:59 +0000 (12:46 +0200)
committerDennis Schafroth <dennis@indexdata.com>
Tue, 15 May 2012 10:46:59 +0000 (12:46 +0200)
25 files changed:
IDMETA
NEWS
src/database.c
src/http_command.c
src/normalize_record.c
src/pazpar2_config.c
src/session.c
src/settings.c
src/settings.h
test/Makefile.am
test/test_limit_limitmap.urls
test/test_limit_limitmap_24.res
test/test_post.urls
test/test_solr.urls
test/test_solr_22.res
test/test_solr_23.res [new file with mode: 0644]
test/test_solr_24.res [new file with mode: 0644]
test/test_solr_25.res [new file with mode: 0644]
test/test_solr_26.res [new file with mode: 0644]
test/test_solr_27.res [new file with mode: 0644]
test/test_solr_28.res [new file with mode: 0644]
test/test_solr_29.res [new file with mode: 0644]
test/test_solr_settings_4.xml
test/test_solr_settings_5.xml [new file with mode: 0644]
test/z3950_indexdata_com_marc.xml

diff --git a/IDMETA b/IDMETA
index 19913f7..a255755 100644 (file)
--- a/IDMETA
+++ b/IDMETA
@@ -1,3 +1,3 @@
 DEBIAN_DIST="wheezy squeeze"
-UBUNTU_DIST="oneiric natty maverick lucid"
+UBUNTU_DIST="precise oneiric natty lucid"
 VERSION=1.6.12
diff --git a/NEWS b/NEWS
index 16bb77d..0d7f4ca 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,23 @@
+Setting pz:xslt may embed local XSLT as an alternative to referring
+to filenames.
+Value is not CDATA but XML nodes embedded, so escaping is not necessary
+but a root element *must* be present. For example:
+<settings target="target="z3950.indexdata.com/marc">
+     <set name="pz:xslt">
+       <xsl:stylesheet
+          version="1.0"
+        ..
+       </xsl:stylesheet>
+     </set>
+    </settings>
+
+Metadata field rank may given by XML internal document (pz:xslt
+result). If rank is not given, the rank from service description is
+used - as before.
+
+New setting, pz:present_chunk, that specifies number of records to fetch
+at a time.
+
 --- 1.6.12 2012/03/14
 
 Revert the format change in termlist response, that could break 
index 21b442c..f45cab5 100644 (file)
@@ -101,7 +101,7 @@ struct database *create_database_for_service(const char *id,
         if (!strcmp(p->id, id))
             return p;
     
-    yaz_log(YLOG_DEBUG, "new database %s under service %s values %p", id, service->id);
+    yaz_log(YLOG_DEBUG, "new database %s under service %s", id, service->id);
     p = new_database_inherit_settings(id, service->nmem, service->settings);
 
     p->next = service->databases;
index d4b4a77..567189e 100644 (file)
@@ -498,6 +498,7 @@ static void cmd_settings(struct http_channel *c)
     {
         xmlDoc *doc = xmlParseMemory(rq->content_buf, rq->content_len);
         xmlNode *root_n;
+        int ret;
         if (!doc)
         {
             error(rs, PAZPAR2_MALFORMED_SETTING, 0);
@@ -505,10 +506,14 @@ static void cmd_settings(struct http_channel *c)
             return;
         }
         root_n = xmlDocGetRootElement(doc);
-
-        settings_read_node_x(root_n, s->psession, apply_local_setting);
-
+        ret = settings_read_node_x(root_n, s->psession, apply_local_setting);
         xmlFreeDoc(doc);
+        if (ret)
+        {
+            error(rs, PAZPAR2_MALFORMED_SETTING, 0);
+            release_session(c,s);
+            return;
+        }            
     }
     if (process_settings(s->psession, rq, rs) < 0)
     {
index 129be2b..90876e5 100644 (file)
@@ -52,52 +52,79 @@ normalize_record_t normalize_record_create(struct conf_service *service,
     NMEM nmem = nmem_create();
     normalize_record_t nt = nmem_malloc(nmem, sizeof(*nt));
     struct normalize_step **m = &nt->steps;
-    int i, num;
     int no_errors = 0;
-    char **stylesheets;
-    struct conf_config *conf = service->server->config;
+    int embed = 0;
+
+    if (*spec == '<')
+        embed = 1;
 
     nt->nmem = nmem;
 
-    nmem_strsplit(nt->nmem, ",", spec, &stylesheets, &num);
-    for (i = 0; i < num; i++)
+    if (embed)
     {
-        WRBUF fname = conf_get_fname(conf, stylesheets[i]);
-        
-        *m = nmem_malloc(nt->nmem, sizeof(**m));
-        (*m)->marcmap = NULL;
-        (*m)->stylesheet = NULL;
-
-        (*m)->stylesheet2 = service_xslt_get(service, stylesheets[i]);
-        if ((*m)->stylesheet2)
-            ;
-        else if (!strcmp(&stylesheets[i][strlen(stylesheets[i])-4], ".xsl")) 
-        {    
-            if (!((*m)->stylesheet =
-                  xsltParseStylesheetFile((xmlChar *) wrbuf_cstr(fname))))
-            {
-                yaz_log(YLOG_FATAL|YLOG_ERRNO, "Unable to load stylesheet: %s",
-                        stylesheets[i]);
+        xmlDoc *xsp_doc = xmlParseMemory(spec, strlen(spec));
+
+        if (!xsp_doc)
+            no_errors++;
+        {
+            *m = nmem_malloc(nt->nmem, sizeof(**m));
+            (*m)->marcmap = NULL;
+            (*m)->stylesheet = NULL;
+            (*m)->stylesheet2 = NULL;
+            
+            
+            (*m)->stylesheet = xsltParseStylesheetDoc(xsp_doc);
+            if (!(*m)->stylesheet)
                 no_errors++;
-            }
+            m = &(*m)->next;
         }
-        else if (!strcmp(&stylesheets[i][strlen(stylesheets[i])-5], ".mmap"))
+    }
+    else
+    {
+        struct conf_config *conf = service->server->config;
+        int i, num;
+        char **stylesheets;
+        nmem_strsplit(nt->nmem, ",", spec, &stylesheets, &num);
+
+        for (i = 0; i < num; i++)
         {
-            if (!((*m)->marcmap = marcmap_load(wrbuf_cstr(fname), nt->nmem)))
+            WRBUF fname = conf_get_fname(conf, stylesheets[i]);
+            
+            *m = nmem_malloc(nt->nmem, sizeof(**m));
+            (*m)->marcmap = NULL;
+            (*m)->stylesheet = NULL;
+            
+            (*m)->stylesheet2 = service_xslt_get(service, stylesheets[i]);
+            if ((*m)->stylesheet2)
+                ;
+            else if (!strcmp(&stylesheets[i][strlen(stylesheets[i])-4], ".xsl")) 
+            {    
+                if (!((*m)->stylesheet =
+                      xsltParseStylesheetFile((xmlChar *) wrbuf_cstr(fname))))
+                {
+                    yaz_log(YLOG_FATAL|YLOG_ERRNO, "Unable to load stylesheet: %s",
+                            stylesheets[i]);
+                    no_errors++;
+                }
+            }
+            else if (!strcmp(&stylesheets[i][strlen(stylesheets[i])-5], ".mmap"))
+            {
+                if (!((*m)->marcmap = marcmap_load(wrbuf_cstr(fname), nt->nmem)))
+                {
+                    yaz_log(YLOG_FATAL|YLOG_ERRNO, "Unable to load marcmap: %s",
+                            stylesheets[i]);
+                    no_errors++;
+                }
+            }
+            else
             {
-                yaz_log(YLOG_FATAL|YLOG_ERRNO, "Unable to load marcmap: %s",
-                        stylesheets[i]);
+                yaz_log(YLOG_FATAL, "Cannot handle stylesheet: %s", stylesheets[i]);
                 no_errors++;
             }
+            
+            wrbuf_destroy(fname);
+            m = &(*m)->next;
         }
-        else
-        {
-            yaz_log(YLOG_FATAL, "Cannot handle stylesheet: %s", stylesheets[i]);
-            no_errors++;
-        }
-
-        wrbuf_destroy(fname);
-        m = &(*m)->next;
     }
     *m = 0;  /* terminate list of steps */
 
index ab4382b..075347e 100644 (file)
@@ -607,19 +607,22 @@ static struct conf_service *service_create_static(struct conf_server *server,
                     continue;
                 if (!strcmp((const char *) n->name, "settings"))
                 {
+                    int ret;
                     xmlChar *src = xmlGetProp(n, (xmlChar *) "src");
                     if (src)
                     {
                         WRBUF w = wrbuf_alloc();
                         conf_dir_path(server->config, w, (const char *) src);
-                        settings_read_file(service, wrbuf_cstr(w), pass);
+                        ret = settings_read_file(service, wrbuf_cstr(w), pass);
                         wrbuf_destroy(w);
                         xmlFree(src);
                     }
                     else
                     {
-                        settings_read_node(service, n, pass);
+                        ret = settings_read_node(service, n, pass);
                     }
+                    if (ret)
+                        return 0;
                 }
             }
         }
@@ -627,8 +630,9 @@ static struct conf_service *service_create_static(struct conf_server *server,
     return service;
 }
 
-static void inherit_server_settings(struct conf_service *s)
+static int inherit_server_settings(struct conf_service *s)
 {
+    int ret = 0;
     struct conf_server *server = s->server;
     if (!s->dictionary) /* service has no config settings ? */
     {
@@ -636,8 +640,10 @@ static void inherit_server_settings(struct conf_service *s)
         {
             /* inherit settings from server */
             init_settings(s);
-            settings_read_file(s, server->settings_fname, 1);
-            settings_read_file(s, server->settings_fname, 2);
+            if (settings_read_file(s, server->settings_fname, 1))
+                ret = -1;
+            if (settings_read_file(s, server->settings_fname, 2))
+                ret = -1;
         }
         else
         {
@@ -660,6 +666,7 @@ static void inherit_server_settings(struct conf_service *s)
             s->charsets = pp2_charset_fact_create();
         }
     }
+    return ret;
 }
 
 struct conf_service *service_create(struct conf_server *server,
index b37b358..0e1eea7 100644 (file)
@@ -408,40 +408,43 @@ const char *session_setting_oneval(struct session_database *db, int offset)
 // setting. However, this is not a realistic use scenario.
 static int prepare_map(struct session *se, struct session_database *sdb)
 {
-    const char *s;
-
-    if (sdb->settings && sdb->settings[PZ_XSLT] && !sdb->map &&
-        (s = session_setting_oneval(sdb, PZ_XSLT)))        
+    if (sdb->settings && !sdb->map)
     {
-        char auto_stylesheet[256];
+        const char *s;
 
-        if (!strcmp(s, "auto"))
+        if (sdb->settings[PZ_XSLT] &&
+            (s = session_setting_oneval(sdb, PZ_XSLT)))        
         {
-            const char *request_syntax = session_setting_oneval(
-                sdb, PZ_REQUESTSYNTAX);
-            if (request_syntax)
+            char auto_stylesheet[256];
+            
+            if (!strcmp(s, "auto"))
             {
-                char *cp;
-                yaz_snprintf(auto_stylesheet, sizeof(auto_stylesheet),
-                             "%s.xsl", request_syntax);
-                for (cp = auto_stylesheet; *cp; cp++)
+                const char *request_syntax = session_setting_oneval(
+                    sdb, PZ_REQUESTSYNTAX);
+                if (request_syntax)
                 {
-                    /* deliberately only consider ASCII */
-                    if (*cp > 32 && *cp < 127)
-                        *cp = tolower(*cp);
+                    char *cp;
+                    yaz_snprintf(auto_stylesheet, sizeof(auto_stylesheet),
+                                 "%s.xsl", request_syntax);
+                    for (cp = auto_stylesheet; *cp; cp++)
+                    {
+                        /* deliberately only consider ASCII */
+                        if (*cp > 32 && *cp < 127)
+                            *cp = tolower(*cp);
+                    }
+                    s = auto_stylesheet;
+                }
+                else
+                {
+                    session_log(se, YLOG_WARN,
+                                "No pz:requestsyntax for auto stylesheet");
                 }
-                s = auto_stylesheet;
-            }
-            else
-            {
-                session_log(se, YLOG_WARN,
-                            "No pz:requestsyntax for auto stylesheet");
             }
+            sdb->map = normalize_cache_get(se->normalize_cache,
+                                           se->service, s);
+            if (!sdb->map)
+                return -1;
         }
-        sdb->map = normalize_cache_get(se->normalize_cache,
-                                       se->service, s);
-        if (!sdb->map)
-            return -1;
     }
     return 0;
 }
index 124d9db..cb55b5e 100644 (file)
@@ -180,70 +180,84 @@ static int isdir(const char *path)
 }
 
 // Read settings from an XML file, calling handler function for each setting
-void settings_read_node_x(xmlNode *n,
-                          void *client_data,
-                          void (*fun)(void *client_data,
-                                      struct setting *set))
+int settings_read_node_x(xmlNode *n,
+                         void *client_data,
+                         void (*fun)(void *client_data,
+                                     struct setting *set))
 {
-    xmlChar *namea, *targeta, *valuea, *usera, *precedencea;
+    int ret_val = 0; /* success */
+    char *namea = (char *) xmlGetProp(n, (xmlChar *) "name");
+    char *targeta = (char *) xmlGetProp(n, (xmlChar *) "target");
+    char *valuea = (char *) xmlGetProp(n, (xmlChar *) "value");
+    char *usera = (char *) xmlGetProp(n, (xmlChar *) "user");
+    char *precedencea = (char *) xmlGetProp(n, (xmlChar *) "precedence");
 
-    namea = xmlGetProp(n, (xmlChar *) "name");
-    targeta = xmlGetProp(n, (xmlChar *) "target");
-    valuea = xmlGetProp(n, (xmlChar *) "value");
-    usera = xmlGetProp(n, (xmlChar *) "user");
-    precedencea = xmlGetProp(n, (xmlChar *) "precedence");
     for (n = n->children; n; n = n->next)
     {
         if (n->type != XML_ELEMENT_NODE)
             continue;
         if (!strcmp((const char *) n->name, "set"))
         {
-            char *name, *target, *value, *user, *precedence;
+            xmlNode *root = n->children;
+            struct setting set;
+            char *name = (char *) xmlGetProp(n, (xmlChar *) "name");
+            char *target = (char *) xmlGetProp(n, (xmlChar *) "target");
+            char *value = (char *) xmlGetProp(n, (xmlChar *) "value");
+            char *user = (char *) xmlGetProp(n, (xmlChar *) "user");
+            char *precedence = (char *) xmlGetProp(n, (xmlChar *) "precedence");
+            xmlChar *buf_out = 0;
+
+            set.next = 0;
+
+            if (precedence)
+                set.precedence = atoi((char *) precedence);
+            else if (precedencea)
+                set.precedence = atoi((char *) precedencea);
+            else
+                set.precedence = 0;
 
-            name = (char *) xmlGetProp(n, (xmlChar *) "name");
-            target = (char *) xmlGetProp(n, (xmlChar *) "target");
-            value = (char *) xmlGetProp(n, (xmlChar *) "value");
-            user = (char *) xmlGetProp(n, (xmlChar *) "user");
-            precedence = (char *) xmlGetProp(n, (xmlChar *) "precedence");
+            set.target = target ? target : targeta;
+            set.name = name ? name : namea;
 
-            if ((!name && !namea) || (!value && !valuea) || (!target && !targeta))
-            {
-                yaz_log(YLOG_FATAL, "set must specify name, value, and target");
-                exit(1);
+            while (root && root->type != XML_ELEMENT_NODE)
+                root = root->next;
+            if (!root)
+                set.value = value ? value : valuea;
+            else
+            {   /* xml document content for this setting */
+                xmlDoc *doc = xmlNewDoc(BAD_CAST "1.0");
+                if (!doc)
+                {
+                    if (set.name)
+                        yaz_log(YLOG_WARN, "bad XML content for setting "
+                                "name=%s", set.name);
+                    else
+                        yaz_log(YLOG_WARN, "bad XML content for setting");
+                    ret_val = -1;
+                }
+                else
+                {
+                    int len_out;
+                    xmlDocSetRootElement(doc, xmlCopyNode(root, 1));
+                    xmlDocDumpMemory(doc, &buf_out, &len_out);
+                    /* xmlDocDumpMemory 0-terminates */
+                    set.value = (char *) buf_out; 
+                    xmlFreeDoc(doc);
+                }
             }
+
+            if (set.name && set.value && set.target)
+                (*fun)(client_data, &set);
             else
             {
-                struct setting set;
-                char nameb[1024];
-                char targetb[1024];
-                char valueb[1024];
-
-                // Copy everything into a temporary buffer -- we decide
-                // later if we are keeping it.
-                if (precedence)
-                    set.precedence = atoi((char *) precedence);
-                else if (precedencea)
-                    set.precedence = atoi((char *) precedencea);
-                else
-                    set.precedence = 0;
-                if (target)
-                    strcpy(targetb, target);
-                else
-                    strcpy(targetb, (const char *) targeta);
-                set.target = targetb;
-                if (name)
-                    strcpy(nameb, name);
-                else
-                    strcpy(nameb, (const char *) namea);
-                set.name = nameb;
-                if (value)
-                    strcpy(valueb, value);
+                if (set.name)
+                    yaz_log(YLOG_WARN, "missing value and/or target for "
+                            "setting name=%s", set.name);
                 else
-                    strcpy(valueb, (const char *) valuea);
-                set.value = valueb;
-                set.next = 0;
-                (*fun)(client_data, &set);
+                    yaz_log(YLOG_WARN, "missing name/value/target for setting");
+                ret_val = -1;
             }
+            xmlFree(buf_out);
             xmlFree(name);
             xmlFree(precedence);
             xmlFree(value);
@@ -252,8 +266,9 @@ void settings_read_node_x(xmlNode *n,
         }
         else
         {
-            yaz_log(YLOG_FATAL, "Unknown element %s in settings file", (char*) n->name);
-            exit(1);
+            yaz_log(YLOG_WARN, "Unknown element %s in settings file", 
+                    (char*) n->name);
+            ret_val = -1;
         }
     }
     xmlFree(namea);
@@ -261,35 +276,39 @@ void settings_read_node_x(xmlNode *n,
     xmlFree(valuea);
     xmlFree(usera);
     xmlFree(targeta);
+    return ret_val;
 }
  
-static void read_settings_file(const char *path,
-                               void *client_data,
-                               void (*fun)(void *client_data,
-                                           struct setting *set))
+static int read_settings_file(const char *path,
+                              void *client_data,
+                              void (*fun)(void *client_data,
+                                          struct setting *set))
 {
     xmlDoc *doc = xmlParseFile(path);
     xmlNode *n;
+    int ret;
 
     if (!doc)
     {
         yaz_log(YLOG_FATAL, "Failed to parse %s", path);
-        exit(1);
+        return -1;
     }
     n = xmlDocGetRootElement(doc);
-    settings_read_node_x(n, client_data, fun);
+    ret = settings_read_node_x(n, client_data, fun);
 
     xmlFreeDoc(doc);
+    return ret;
 }
 
 
 // Recursively read files or directories, invoking a 
 // callback for each one
-static void read_settings(const char *path,
+static int read_settings(const char *path,
                           void *client_data,
                           void (*fun)(void *client_data,
                                       struct setting *set))
 {
+    int ret = 0;
     DIR *d;
     struct dirent *de;
     char *dot;
@@ -299,7 +318,7 @@ static void read_settings(const char *path,
         if (!(d = opendir(path)))
         {
             yaz_log(YLOG_FATAL|YLOG_ERRNO, "%s", path);
-            exit(1);
+            return -1;
         }
         while ((de = readdir(d)))
         {
@@ -307,12 +326,14 @@ static void read_settings(const char *path,
             if (*de->d_name == '.' || !strcmp(de->d_name, "CVS"))
                 continue;
             sprintf(tmp, "%s/%s", path, de->d_name);
-            read_settings(tmp, client_data, fun);
+            if (read_settings(tmp, client_data, fun))
+                ret = -1;
         }
         closedir(d);
     }
     else if ((dot = strrchr(path, '.')) && !strcmp(dot + 1, "xml"))
-        read_settings_file(path, client_data, fun);
+        ret = read_settings_file(path, client_data, fun);
+    return ret;
 }
 
 // Determines if a ZURL is a wildcard, and what kind
@@ -560,22 +581,22 @@ void init_settings(struct conf_service *service)
     initialize_soft_settings(service);
 }
 
-void settings_read_file(struct conf_service *service, const char *path,
-                        int pass)
+int settings_read_file(struct conf_service *service, const char *path,
+                       int pass)
 {
     if (pass == 1)
-        read_settings(path, service, prepare_target_dictionary);
+        return read_settings(path, service, prepare_target_dictionary);
     else
-        read_settings(path, service, update_databases);
+        return read_settings(path, service, update_databases);
 }
 
-void settings_read_node(struct conf_service *service, xmlNode *n,
+int settings_read_node(struct conf_service *service, xmlNode *n,
                         int pass)
 {
     if (pass == 1)
-        settings_read_node_x(n, service, prepare_target_dictionary);
+        return settings_read_node_x(n, service, prepare_target_dictionary);
     else
-        settings_read_node_x(n, service, update_databases);
+        return settings_read_node_x(n, service, update_databases);
 }
 
 /*
index 5826ac6..a746dfa 100644 (file)
@@ -72,18 +72,17 @@ struct settings
     int num_settings;
 };
 
-void settings_read_file(struct conf_service *service, const char *path,
-                        int pass);
-void settings_read_node(struct conf_service *service, xmlNode *n,
-                        int pass);
+int settings_read_file(struct conf_service *service, const char *path,
+                       int pass);
+int settings_read_node(struct conf_service *service, xmlNode *n, int pass);
 int settings_num(struct conf_service *service);
 int settings_create_offset(struct conf_service *service, const char *name);
 int settings_lookup_offset(struct conf_service *service, const char *name);
 void init_settings(struct conf_service *service);
-void settings_read_node_x(xmlNode *n,
-                          void *client_data,
-                          void (*fun)(void *client_data,
-                                      struct setting *set));
+int settings_read_node_x(xmlNode *n,
+                         void *client_data,
+                         void (*fun)(void *client_data,
+                                     struct setting *set));
 void expand_settings_array(struct setting ***set_ar, int *num, int offset,
                            NMEM nmem);
 
index 1699ff0..24b417f 100644 (file)
@@ -1,8 +1,11 @@
 # This file is part of Pazpar2.
+
+# These tests require a Solr target
+solr_tests = test_solr.sh test_termlist_block.sh test_limit_limitmap.sh
 check_SCRIPTS = test_http.sh test_icu.sh test_post.sh \
  test_settings.sh test_turbomarcxml.sh test_facets.sh \
- test_solr.sh test_url.sh test_filter.sh \
- test_termlist_block.sh test_limit_limitmap.sh
+ test_url.sh test_filter.sh \
+ $(solr_tests)
 
 EXTRA_DIST = run_pazpar2.sh marc21_test.xsl tmarc.xsl solr-pz2.xsl \
        z3950_indexdata_com_marc.xml \
@@ -13,7 +16,7 @@ EXTRA_DIST = run_pazpar2.sh marc21_test.xsl tmarc.xsl solr-pz2.xsl \
        test_post.cfg test_post.urls \
        test_settings.cfg test_settings.urls \
        test_solr.cfg test_solr.urls \
-       test_solr_settings_1.xml  test_solr_settings_2.xml  test_solr_settings_3.xml  test_solr_settings_4.xml \
+       test_solr_settings_1.xml  test_solr_settings_2.xml  test_solr_settings_3.xml  test_solr_settings_4.xml test_solr_settings_5.xml \
        test_turbomarcxml.cfg test_turbomarcxml.urls \
        test_url.cfg test_url.urls \
        test_filter.cfg test_filter.urls \
index a986e6b..e40b12d 100644 (file)
@@ -21,6 +21,6 @@ http://localhost:9763/search.pz2?session=1&command=bytarget
 http://localhost:9763/search.pz2?session=1&command=show
 test_limit_limitmap_settings_4.xml http://localhost:9763/search.pz2?session=1&command=settings
 http://localhost:9763/search.pz2?session=1&command=search&query=computer&limit=Mysubject%3DRailroads
-http://localhost:9763/search.pz2?session=1&command=show&block=1
+1 http://localhost:9763/search.pz2?session=1&command=show&block=1
 http://localhost:9763/search.pz2?session=1&command=search&query=computer&limit=date%3D1977
-http://localhost:9763/search.pz2?session=1&command=show&block=1
\ No newline at end of file
+http://localhost:9763/search.pz2?session=1&command=show&block=1
index 9f9ccad..64ca61c 100644 (file)
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <show><status>OK</status>
-<activeclients>2</activeclients>
-<merged>60</merged>
-<total>2015</total>
+<activeclients>0</activeclients>
+<merged>109</merged>
+<total>2025</total>
 <start>0</start>
 <num>20</num>
 <hit>
@@ -15,7 +15,7 @@
 <md-title-remainder>fast &amp; easy</md-title-remainder>
 <md-date>2001</md-date>
 <md-author>Woodward, C. Michael</md-author></location>
-<relevance>30776</relevance>
+<relevance>45304</relevance>
 <recid>content: title adobe illustrator for the mac author woodward c michael</recid>
 </hit>
 <hit>
@@ -24,7 +24,7 @@
 <md-date>1998</md-date><location id="Target-2" name="LOC-SOLR">
 <md-title>Advanced computer performance modeling and simulation</md-title>
 <md-date>1998</md-date></location>
-<relevance>30776</relevance>
+<relevance>45304</relevance>
 <recid>content: title advanced computer performance modeling and simulation</recid>
 </hit>
 <hit>
@@ -39,7 +39,7 @@
 <md-date>2000</md-date>
 <md-author>Aldrich, Richard W</md-author>
 <md-description>&quot;April 2000.&quot;</md-description></location>
-<relevance>30776</relevance>
+<relevance>45304</relevance>
 <recid>content: title cyberterrorism and computer crimes author aldrich richard w</recid>
 </hit>
 <hit>
@@ -52,7 +52,7 @@
 <md-title-remainder>talks with Bonnie Nardi, Jakob Nielsen, David Smith, Austin Henderson &amp; Jed Harris, Terry Winograd, Stephanie Rosenbaum</md-title-remainder>
 <md-date>2000</md-date>
 <md-author>Kaasgaard, Klaus</md-author></location>
-<relevance>28211</relevance>
+<relevance>41529</relevance>
 <recid>content: title software design and usability author kaasgaard klaus</recid>
 </hit>
 <hit>
 <md-date>2000</md-date>
 <md-author>Knittel, John</md-author>
 <md-description>Explains what computer hacking is, who does it, and how dangerous it can be</md-description></location>
-<relevance>26979</relevance>
+<relevance>39715</relevance>
 <recid>content: title everything you need to know about the dangers of computer hacking author knittel john</recid>
 </hit>
 <hit>
 
+<md-title>Computer peripherals</md-title>
+<md-date>1995</md-date>
+<md-author>Cook, Barry M</md-author><location id="Target-2" name="LOC-SOLR">
+<md-title>Computer peripherals</md-title>
+<md-date>1995</md-date>
+<md-author>Cook, Barry M</md-author></location>
+<relevance>39641</relevance>
+<recid>content: title computer peripherals author cook barry m</recid>
+</hit>
+<hit>
+
 <md-title>Kids&apos; computer book</md-title>
 <md-date>1994</md-date>
 <md-description>Discusses a variety of educational and game software for children  with suggestions for setting up a computer system. Includes a 3 1/2 in. disk with 6 shareware programs for children</md-description><location id="Target-2" name="LOC-SOLR">
@@ -77,7 +88,7 @@
 <md-date>1994</md-date>
 <md-description>&quot;For kids and their parents&quot;--Cover</md-description>
 <md-description>Discusses a variety of educational and game software for children  with suggestions for setting up a computer system. Includes a 3 1/2 in. disk with 6 shareware programs for children</md-description></location>
-<relevance>23651</relevance>
+<relevance>34817</relevance>
 <recid>content: title kids computer book</recid>
 </hit>
 <hit>
@@ -88,7 +99,7 @@
 <md-title>Computer friendly</md-title>
 <md-date>1999</md-date>
 <md-author>Steinbacher, Raymond</md-author></location>
-<relevance>23082</relevance>
+<relevance>33978</relevance>
 <recid>content: title computer friendly author steinbacher raymond</recid>
 </hit>
 <hit>
 <md-description>&quot;May 1999.&quot;</md-description>
 <md-description>&quot;NZLC R54&quot;--T.p. verso</md-description>
 <md-description>&quot;Also published as Parliamentary Paper E 31AO&quot;--T.p. verso</md-description></location>
-<relevance>23082</relevance>
+<relevance>33978</relevance>
 <recid>content: title computer misuse</recid>
 </hit>
 <hit>
 
+<md-title>Computer networking</md-title>
+<md-title-remainder>a top-down approach featuring the Internet</md-title-remainder>
+<md-date>2001</md-date>
+<md-author>Ross, Keith W</md-author><location id="Target-2" name="LOC-SOLR">
+<md-title>Computer networking</md-title>
+<md-title-remainder>a top-down approach featuring the Internet</md-title-remainder>
+<md-date>2001</md-date>
+<md-author>Ross, Keith W</md-author></location>
+<relevance>33978</relevance>
+<recid>content: title computer networking author ross keith w</recid>
+</hit>
+<hit>
+
+<md-title>CorelDRAW 8 for Windows</md-title>
+<md-date>1998</md-date>
+<md-author>Davis, Phyllis</md-author>
+<md-description>Includes index</md-description><location id="Target-2" name="LOC-SOLR">
+<md-title>CorelDRAW 8 for Windows</md-title>
+<md-date>1998</md-date>
+<md-author>Davis, Phyllis</md-author>
+<md-description>Includes index</md-description></location>
+<relevance>33978</relevance>
+<recid>content: title coreldraw for windows author davis phyllis</recid>
+</hit>
+<hit>
+
 <md-title>Quicken 2000 for the Mac</md-title>
 <md-title-remainder>the official guide</md-title-remainder>
 <md-date>2000</md-date>
 <md-author>Langer, Maria</md-author>
 <md-description>Includes index</md-description>
 <md-description>&quot;Covers Quicken deluxe 2000 for the Mac&quot;--Cover</md-description></location>
-<relevance>23082</relevance>
+<relevance>33978</relevance>
 <recid>content: title quicken for the mac author langer maria</recid>
 </hit>
 <hit>
 
+<md-title>Sicherheit und Schutz im Netz</md-title>
+<md-date>1998</md-date><location id="Target-2" name="LOC-SOLR">
+<md-title>Sicherheit und Schutz im Netz</md-title>
+<md-date>1998</md-date></location>
+<relevance>33978</relevance>
+<recid>content: title sicherheit und schutz im netz</recid>
+</hit>
+<hit>
+
 <md-title>Unix Secure Shell</md-title>
 <md-date>1999</md-date>
 <md-author>Carasik, Anne H</md-author>
 <md-date>1999</md-date>
 <md-author>Carasik, Anne H</md-author>
 <md-description>Includes index</md-description></location>
-<relevance>23082</relevance>
+<relevance>33978</relevance>
 <recid>content: title unix secure shell author carasik anne h</recid>
 </hit>
 <hit>
 <md-title-remainder>proceedings, 11-13 October 1999, Boston, Massachusetts</md-title-remainder>
 <md-date>1999</md-date>
 <md-description>&quot;IEEE catalog number 99EX370&quot;--T.p. verso</md-description></location>
-<relevance>21799</relevance>
+<relevance>32090</relevance>
 <recid>content: title eight international conference on computer communications and networks</recid>
 </hit>
 <hit>
 
+<md-title>Building storage networks</md-title>
+<md-date>2000</md-date>
+<md-author>Farley, Marc</md-author>
+<md-description>Includes index</md-description><location id="Target-2" name="LOC-SOLR">
+<md-title>Building storage networks</md-title>
+<md-date>2000</md-date>
+<md-author>Farley, Marc</md-author>
+<md-description>Includes index</md-description></location>
+<relevance>30203</relevance>
+<recid>content: title building storage networks author farley marc</recid>
+</hit>
+<hit>
+
 <md-title>Complete CL</md-title>
 <md-title-remainder>the definitive control language programming guide</md-title-remainder>
 <md-date>1999</md-date>
 <md-date>1999</md-date>
 <md-author>Malaga, Ernie</md-author>
 <md-description>Includes index</md-description></location>
-<relevance>20517</relevance>
+<relevance>30203</relevance>
 <recid>content: title complete cl author malaga ernie</recid>
 </hit>
 <hit>
 <md-title-remainder>real-time rendering and software technology</md-title-remainder>
 <md-date>2001</md-date>
 <md-author>Watt, Alan H</md-author></location>
-<relevance>20517</relevance>
+<relevance>30203</relevance>
 <recid>content: title d games author watt alan h</recid>
 </hit>
 <hit>
 
+<md-title>Java applications strategies for the AS/400</md-title>
+<md-date>1999</md-date>
+<md-author>Denoncourt, Don</md-author><location id="Target-2" name="LOC-SOLR">
+<md-title>Java applications strategies for the AS/400</md-title>
+<md-date>1999</md-date>
+<md-author>Denoncourt, Don</md-author></location>
+<relevance>30203</relevance>
+<recid>content: title java applications strategies for the as author denoncourt don</recid>
+</hit>
+<hit>
+
 <md-title>Mastering algorithms with C</md-title>
 <md-date>1999</md-date>
 <md-author>Loudon, Kyle</md-author>
 <md-author>Loudon, Kyle</md-author>
 <md-description>&quot;Useful techniques from sorting to encryption&quot;--Cover</md-description>
 <md-description>Includes index</md-description></location>
-<relevance>20517</relevance>
+<relevance>30203</relevance>
 <recid>content: title mastering algorithms with c author loudon kyle</recid>
 </hit>
-<hit>
-
-<md-title>Programming Web graphics with PERL and GNU software</md-title>
-<md-date>1999</md-date>
-<md-author>Wallace, Shawn P</md-author><location id="Target-2" name="LOC-SOLR">
-<md-title>Programming Web graphics with PERL and GNU software</md-title>
-<md-date>1999</md-date>
-<md-author>Wallace, Shawn P</md-author></location>
-<relevance>20517</relevance>
-<recid>content: title programming web graphics with perl and gnu software author wallace shawn p</recid>
-</hit>
-<hit>
-
-<md-title>4th ACM Conference on Computer and Communications Security, April 1-4, 1997, Zurich, Switzerland</md-title>
-<md-date>1997</md-date><location id="Target-2" name="LOC-SOLR">
-<md-title>4th ACM Conference on Computer and Communications Security, April 1-4, 1997, Zurich, Switzerland</md-title>
-<md-date>1997</md-date></location>
-<relevance>18185</relevance>
-<recid>content: title th acm conference on computer and communications security april zurich switzerland</recid>
-</hit>
-<hit>
-
-<md-title>3D computer graphics</md-title>
-<md-date>2000</md-date>
-<md-author>Watt, Alan H</md-author><location id="Target-2" name="LOC-SOLR">
-<md-title>3D computer graphics</md-title>
-<md-date>2000</md-date>
-<md-author>Watt, Alan H</md-author></location>
-<relevance>17952</relevance>
-<recid>content: title d computer graphics author watt alan h</recid>
-</hit>
-<hit>
-
-<md-title>Insanely great</md-title>
-<md-title-remainder>the life and times of Macintosh, the computer that changed everything</md-title-remainder>
-<md-date>2000</md-date>
-<md-author>Levy, Steven</md-author><location id="Target-2" name="LOC-SOLR">
-<md-title>Insanely great</md-title>
-<md-title-remainder>the life and times of Macintosh, the computer that changed everything</md-title-remainder>
-<md-date>2000</md-date>
-<md-author>Levy, Steven</md-author></location>
-<relevance>17719</relevance>
-<recid>content: title insanely great author levy steven</recid>
-</hit>
-<hit>
-
-<md-title>Careers in computer animation</md-title>
-<md-date>2001</md-date>
-<md-author>Shires, Jeremy</md-author><location id="Target-2" name="LOC-SOLR">
-<md-title>Careers in computer animation</md-title>
-<md-date>2001</md-date>
-<md-author>Shires, Jeremy</md-author></location>
-<relevance>15388</relevance>
-<recid>content: title careers in computer animation author shires jeremy</recid>
-</hit>
-<hit>
-
-<md-title>Hackers beware</md-title>
-<md-date>2002</md-date>
-<md-author>Cole, Eric</md-author><location id="Target-2" name="LOC-SOLR">
-<md-title>Hackers beware</md-title>
-<md-date>2002</md-date>
-<md-author>Cole, Eric</md-author></location>
-<relevance>15388</relevance>
-<recid>content: title hackers beware author cole eric</recid>
-</hit>
 </show>
\ No newline at end of file
index 3bf0975..0531283 100644 (file)
@@ -1,12 +1,11 @@
 marc_service.xml http://localhost:9763/search.pz2?command=init
-http://localhost:9763/search.pz1?session=1&command=search&query=computer
+http://localhost:9763/search.pz2?session=1&command=search&query=computer
 gils_service.xml http://localhost:9763/search.pz2?command=init
-http://localhost:9763/search.pz1?session=2&command=search&query=computer
+http://localhost:9763/search.pz2?session=2&command=search&query=computer
 gils_service.xml http://localhost:9763/search.pz2?command=init&clear=1
-z3950_indexdata_com_marc.xml
-http://localhost:9763/search.pz1?session=3&command=settings
-http://localhost:9763/search.pz1?session=3&command=search&query=computer
-2 http://localhost:9763/search.pz1?session=1&command=show
-http://localhost:9763/search.pz1?session=2&command=show
-http://localhost:9763/search.pz1?session=3&command=show
-http://localhost:9763/search.pz1?session=3&command=bytarget
+z3950_indexdata_com_marc.xml http://localhost:9763/search.pz2?session=3&command=settings
+http://localhost:9763/search.pz2?session=3&command=search&query=computer
+2 http://localhost:9763/search.pz2?session=1&command=show
+http://localhost:9763/search.pz2?session=2&command=show
+http://localhost:9763/search.pz2?session=3&command=show
+http://localhost:9763/search.pz2?session=3&command=bytarget
index e056172..8b89896 100644 (file)
@@ -18,5 +18,12 @@ http://localhost:9763/search.pz2?session=1&command=search&query=water
 3 http://localhost:9763/search.pz2?session=1&command=show
 http://localhost:9763/search.pz2?session=1&command=bytarget
 http://localhost:9763/search.pz2?session=1&command=termlist&name=xtargets%2Csubject%2Cauthor%2Cdate%2Cmedium
-http://localhost:9763/search.pz2?session=1&command=search&query=water&limit=subject%3A=N.Y
+http://localhost:9763/search.pz2?session=1&command=search&query=water&limit=subject%3DN.Y
+3 http://localhost:9763/search.pz2?session=1&command=show
+test_solr_settings_5.xml http://localhost:9763/search.pz2?session=1&command=settings
+http://localhost:9763/search.pz2?session=1&command=search&query=water
+3 http://localhost:9763/search.pz2?session=1&command=show
+http://localhost:9763/search.pz2?session=1&command=bytarget
+http://localhost:9763/search.pz2?session=1&command=termlist&name=xtargets%2Csubject%2Cauthor%2Cdate%2Cmedium
+http://localhost:9763/search.pz2?session=1&command=search&query=water&limit=subject%3DN.Y
 3 http://localhost:9763/search.pz2?session=1&command=show
index 79896b2..00b1fd7 100644 (file)
 <?xml version="1.0" encoding="UTF-8"?>
 <show><status>OK</status>
 <activeclients>0</activeclients>
-<merged>195</merged>
-<total>1995</total>
+<merged>2</merged>
+<total>2</total>
 <start>0</start>
-<num>20</num>
+<num>2</num>
 <hit>
 
-<md-title>Water</md-title>
-<md-date>1999</md-date>
-<md-author>De Villiers, Marq</md-author>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water</md-title>
-<md-date>1999</md-date>
-<md-author>De Villiers, Marq</md-author>
-<md-medium>book</md-medium></location>
-<relevance>29115</relevance>
-<recid>content: title water author de villiers marq medium book</recid>
-</hit>
-<hit>
-
-<md-title>Potable water and methods of detecting impurities</md-title>
-<md-date>1899-1906</md-date>
-<md-author>Baker, M. N</md-author>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Potable water and methods of detecting impurities</md-title>
-<md-date>1906</md-date>
-<md-author>Baker, M. N</md-author>
-<md-medium>book</md-medium></location>
-<location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Potable water and methods of detecting impurities</md-title>
-<md-date>1899</md-date>
-<md-author>Baker, M. N</md-author>
-<md-medium>book</md-medium></location>
-<count>2</count>
-<relevance>27126</relevance>
-<recid>content: title potable water and methods of detecting impurities author baker m n medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water</md-title>
-<md-date>2000</md-date>
-<md-author>Majeed, Abdul</md-author>
-<md-description>&quot;Balochistan conservation strategy background paper&quot;--T.p</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water</md-title>
-<md-date>2000</md-date>
-<md-author>Majeed, Abdul</md-author>
-<md-description>&quot;Balochistan conservation strategy background paper&quot;--T.p</md-description>
-<md-medium>book</md-medium></location>
-<relevance>25317</relevance>
-<recid>content: title water author majeed abdul medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water</md-title>
-<md-date>2000</md-date>
-<md-author>Grant, Pamela</md-author>
-<md-description>Examines major environmental issues surrounding water, giving examples of attempts to solve global problems and sources for more information</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water</md-title>
-<md-date>2000</md-date>
-<md-author>Grant, Pamela</md-author>
-<md-description>Includes index</md-description>
-<md-description>Examines major environmental issues surrounding water, giving examples of attempts to solve global problems and sources for more information</md-description>
-<md-medium>book</md-medium></location>
-<relevance>23185</relevance>
-<recid>content: title water author grant pamela medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water law</md-title>
-<md-date>2000</md-date>
-<md-author>Fisher, D. E</md-author>
-<md-description>Includes index</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water law</md-title>
-<md-date>2000</md-date>
-<md-author>Fisher, D. E</md-author>
-<md-description>Includes index</md-description>
-<md-medium>book</md-medium></location>
-<relevance>22786</relevance>
-<recid>content: title water law author fisher d e medium book</recid>
-</hit>
-<hit>
-
-<md-title>A Primer on fresh water</md-title>
-<md-title-remainder>questions and answers</md-title-remainder>
-<md-date>2000</md-date>
-<md-description>Issued also in French under title: Notions élémentaires sur l&apos;eau douce : questions et réponses</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>A Primer on fresh water</md-title>
-<md-title-remainder>questions and answers</md-title-remainder>
-<md-date>2000</md-date>
-<md-description>Issued also in French under title: Notions élémentaires sur l&apos;eau douce : questions et réponses</md-description>
-<md-description>Includes index</md-description>
-<md-medium>book</md-medium></location>
-<relevance>22026</relevance>
-<recid>content: title a primer on fresh water medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water and water supplies</md-title>
-<md-date>1901</md-date>
-<md-author>Thresh, John Clough</md-author>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water and water supplies</md-title>
-<md-date>1901</md-date>
-<md-author>Thresh, John Clough</md-author>
-<md-medium>book</md-medium></location>
-<relevance>18988</relevance>
-<recid>content: title water and water supplies author thresh john clough medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water quality assessment of the State Water Project, 1996-97</md-title>
-<md-date>1999-2000</md-date>
-<md-description>&quot;September 1999.&quot;</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water quality assessment of the State Water Project, 1998-99</md-title>
-<md-date>2000</md-date>
-<md-description>Cover title</md-description>
-<md-description>&quot;July 2000.&quot;</md-description>
-<md-medium>book</md-medium></location>
-<location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water quality assessment of the State Water Project, 1996-97</md-title>
-<md-date>1999</md-date>
-<md-description>Cover title</md-description>
-<md-description>&quot;September 1999.&quot;</md-description>
-<md-medium>book</md-medium></location>
-<count>2</count>
-<relevance>18988</relevance>
-<recid>content: title water quality assessment of the state water project medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water-supply</md-title>
-<md-title-remainder>(Considered principally from a sanitary standpoint.)</md-title-remainder>
-<md-date>1896</md-date>
-<md-author>Mason, William Pitt</md-author>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water-supply</md-title>
-<md-title-remainder>(Considered principally from a sanitary standpoint.)</md-title-remainder>
-<md-date>1896</md-date>
-<md-author>Mason, William Pitt</md-author>
-<md-medium>book</md-medium></location>
-<relevance>18988</relevance>
-<recid>content: title water supply author mason william pitt medium book</recid>
-</hit>
-<hit>
-
-<md-title>The law of waters and water rights</md-title>
-<md-title-remainder>international, national, state, municipal, and individual, including irrigation, drainage, and municipal water supply</md-title-remainder>
-<md-date>1904</md-date>
-<md-author>Farnham, Henry P</md-author>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>The law of waters and water rights</md-title>
-<md-title-remainder>international, national, state, municipal, and individual, including irrigation, drainage, and municipal water supply</md-title-remainder>
-<md-date>1904</md-date>
-<md-author>Farnham, Henry P</md-author>
-<md-medium>book</md-medium></location>
-<relevance>18334</relevance>
-<recid>content: title the law of waters and water rights author farnham henry p medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water, in press, 1998</md-title>
-<md-title-remainder>an index of news items on water resources selected from leading news papers</md-title-remainder>
-<md-date>1998-1999</md-date>
-<md-description>With reference to India</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water, in press, 1998</md-title>
-<md-title-remainder>an index to news items on water resources selected from leading news papers</md-title-remainder>
-<md-date>1999</md-date>
-<md-description>Includes index</md-description>
-<md-medium>book</md-medium></location>
-<location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water in press, 1997</md-title>
-<md-title-remainder>an index of news items on water resources selected from leading news papers</md-title-remainder>
-<md-date>1998</md-date>
-<md-description>Includes index</md-description>
-<md-description>With reference to India</md-description>
-<md-medium>book</md-medium></location>
-<count>2</count>
-<relevance>17138</relevance>
-<recid>content: title water in press medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water-power</md-title>
-<md-title-remainder>an outline of the development and application of the energy of flowing water</md-title-remainder>
-<md-date>1900-1901</md-date>
-<md-author>Frizell, Joseph P</md-author>
-<md-description>Original imprint 1901, corrected to 1900</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water-power</md-title>
-<md-title-remainder>an outline of the development and application of the energy of flowing water</md-title-remainder>
-<md-date>1901</md-date>
-<md-author>Frizell, Joseph P</md-author>
-<md-medium>book</md-medium></location>
-<location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water-power</md-title>
-<md-title-remainder>an outline of the development and application of the energy of flowing water</md-title-remainder>
-<md-date>1900</md-date>
-<md-author>Frizell, Joseph P</md-author>
-<md-description>Original imprint 1901, corrected to 1900</md-description>
-<md-medium>book</md-medium></location>
-<count>2</count>
-<relevance>17138</relevance>
-<recid>content: title water power author frizell joseph p medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water-supply engineering</md-title>
-<md-title-remainder>The designing, construction, and maintenance of water-supply systems, both city and irrigation</md-title-remainder>
-<md-date>1903-1909</md-date>
-<md-author>Folwell, Amory Prescott</md-author>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water-supply engineering</md-title>
-<md-title-remainder>The designing, construction, and maintenance of water-supply systems, both city and irrigation</md-title-remainder>
-<md-date>1909</md-date>
-<md-author>Folwell, Amory Prescott</md-author>
-<md-medium>book</md-medium></location>
-<location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water-supply engineering</md-title>
-<md-title-remainder>The designing, construction, and maintenance of water-supply systems, both city and irrigation</md-title-remainder>
-<md-date>1903</md-date>
-<md-author>Folwell, Amory Prescott</md-author>
-<md-medium>book</md-medium></location>
-<count>2</count>
-<relevance>17138</relevance>
-<recid>content: title water supply engineering author folwell amory prescott medium book</recid>
-</hit>
-<hit>
-
-<md-title>Regulations on the disposal of arsenic residuals from drinking water treatment plants</md-title>
+<md-title>The nitrogen permitting and trading plan for Long Island Sound</md-title>
 <md-date>2000</md-date>
-<md-description>&quot;EPA Contract 68-C7-0011, work assignment 0-38.&quot;</md-description>
+<md-description>&quot;In response to Special Act No. 99-6.&quot;</md-description>
 <md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Regulations on the disposal of arsenic residuals from drinking water treatment plants</md-title>
+<md-title>The nitrogen permitting and trading plan for Long Island Sound</md-title>
 <md-date>2000</md-date>
-<md-description>&quot;May 2000.&quot;</md-description>
-<md-description>&quot;EPA/600/R-00/025.&quot;</md-description>
-<md-description>&quot;EPA Contract 68-C7-0011, work assignment 0-38.&quot;</md-description>
-<md-medium>book</md-medium></location>
-<relevance>17089</relevance>
-<recid>content: title regulations on the disposal of arsenic residuals from drinking water treatment plants medium book</recid>
-</hit>
-<hit>
-
-<md-title>A guide to Montana water quality regulation</md-title>
-<md-date>1997</md-date>
-<md-author>Bryan, Michelle</md-author>
-<md-description>&quot;A joint publication of Legislative Environmental Policy Office, Environmental Quality Council [and] Montana University System, Water Center&quot;</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>A guide to Montana water quality regulation</md-title>
-<md-date>1997</md-date>
-<md-author>Bryan, Michelle</md-author>
-<md-description>&quot;A joint publication of Legislative Environmental Policy Office, Environmental Quality Council [and] Montana University System, Water Center&quot;</md-description>
-<md-medium>book</md-medium></location>
-<relevance>16541</relevance>
-<recid>content: title a guide to montana water quality regulation author bryan michelle medium book</recid>
-</hit>
-<hit>
-
-<md-title>Water technology management</md-title>
-<md-date>2001</md-date>
-<md-description>Collection of articles with reference to India</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Water technology management</md-title>
-<md-date>2001</md-date>
-<md-description>Collection of articles with reference to India</md-description>
-<md-medium>book</md-medium></location>
-<relevance>16456</relevance>
-<recid>content: title water technology management medium book</recid>
-</hit>
-<hit>
-
-<md-title>Aquatic habitat indicators and their application to water quality objectives within the Clean Water Act</md-title>
-<md-date>1999</md-date>
-<md-author>Bauer, Steve</md-author>
-<md-description>&quot;This document was developed for US Environmental Protection Agency, Region 10, Seattle Washington, with the Idaho Water Resources Institute, University of Idaho.&quot;</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Aquatic habitat indicators and their application to water quality objectives within the Clean Water Act</md-title>
-<md-date>1999</md-date>
-<md-author>Bauer, Steve</md-author>
-<md-description>&quot;This document was developed for US Environmental Protection Agency, Region 10, Seattle Washington, with the Idaho Water Resources Institute, University of Idaho.&quot;</md-description>
-<md-medium>book</md-medium></location>
-<relevance>16311</relevance>
-<recid>content: title aquatic habitat indicators and their application to water quality objectives within the clean water act author bauer steve medium book</recid>
-</hit>
-<hit>
-
-<md-title>An empirical analysis of water temperature and dissolved oxygen conditions in the Red Deer River</md-title>
-<md-date>1997</md-date>
-<md-author>Saffran, Karen Anita</md-author>
-<md-description>&quot;March 1997.&quot;</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>An empirical analysis of water temperature and dissolved oxygen conditions in the Red Deer River</md-title>
-<md-date>1997</md-date>
-<md-author>Saffran, Karen Anita</md-author>
-<md-description>&quot;March 1997.&quot;</md-description>
-<md-medium>book</md-medium></location>
-<relevance>16203</relevance>
-<recid>content: title an empirical analysis of water temperature and dissolved oxygen conditions in the red deer river author saffran karen anita medium book</recid>
-</hit>
-<hit>
-
-<md-title>Surface water quality monitoring procedures manual</md-title>
-<md-date>1999</md-date>
-<md-description>&quot;GI-252&quot;--Cover</md-description>
-<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>Surface water quality monitoring procedures manual</md-title>
-<md-date>1999</md-date>
-<md-description>&quot;June 1999.&quot;</md-description>
-<md-description>&quot;GI-252&quot;--Cover</md-description>
+<md-description>Title from cover</md-description>
+<md-description>&quot;January 2000.&quot;</md-description>
+<md-description>&quot;In response to Special Act No. 99-6.&quot;</md-description>
 <md-medium>book</md-medium></location>
-<relevance>15823</relevance>
-<recid>content: title surface water quality monitoring procedures manual medium book</recid>
+<relevance>300000</relevance>
+<recid>content: title the nitrogen permitting and trading plan for long island sound medium book</recid>
 </hit>
 <hit>
 
-<md-title>International Conference on Management of Drinking Water Resources, Chennai, December 3-5, 1997</md-title>
-<md-title-remainder>proceedings</md-title-remainder>
-<md-date>1997</md-date>
+<md-title>Report of the Water commissioners to the Common council of the city of Albany;</md-title>
+<md-date>1872</md-date>
 <md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
-<md-title>International Conference on Management of Drinking Water Resources, Chennai, December 3-5, 1997</md-title>
-<md-title-remainder>proceedings</md-title-remainder>
-<md-date>1997</md-date>
+<md-title>Report of the Water commissioners to the Common council of the city of Albany;</md-title>
+<md-date>1872</md-date>
 <md-medium>book</md-medium></location>
-<relevance>15443</relevance>
-<recid>content: title international conference on management of drinking water resources chennai december medium book</recid>
+<relevance>192857</relevance>
+<recid>content: title report of the water commissioners to the common council of the city of albany medium book</recid>
 </hit>
 </show>
\ No newline at end of file
diff --git a/test/test_solr_23.res b/test/test_solr_23.res
new file mode 100644 (file)
index 0000000..42534e3
--- /dev/null
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<settings><status>OK</status></settings>
\ No newline at end of file
diff --git a/test/test_solr_24.res b/test/test_solr_24.res
new file mode 100644 (file)
index 0000000..ab63fe6
--- /dev/null
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<search><status>OK</status></search>
\ No newline at end of file
diff --git a/test/test_solr_25.res b/test/test_solr_25.res
new file mode 100644 (file)
index 0000000..83670b4
--- /dev/null
@@ -0,0 +1,311 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<show><status>OK</status>
+<activeclients>0</activeclients>
+<merged>97</merged>
+<total>1995</total>
+<start>0</start>
+<num>20</num>
+<hit>
+
+<md-title>Water</md-title>
+<md-date>1999</md-date>
+<md-author>De Villiers, Marq</md-author>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water</md-title>
+<md-date>1999</md-date>
+<md-author>De Villiers, Marq</md-author>
+<md-medium>book</md-medium></location>
+<relevance>23233</relevance>
+<recid>content: title water author de villiers marq medium book</recid>
+</hit>
+<hit>
+
+<md-title>Potable water and methods of detecting impurities</md-title>
+<md-date>1899-1906</md-date>
+<md-author>Baker, M. N</md-author>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Potable water and methods of detecting impurities</md-title>
+<md-date>1906</md-date>
+<md-author>Baker, M. N</md-author>
+<md-medium>book</md-medium></location>
+<location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Potable water and methods of detecting impurities</md-title>
+<md-date>1899</md-date>
+<md-author>Baker, M. N</md-author>
+<md-medium>book</md-medium></location>
+<count>2</count>
+<relevance>21645</relevance>
+<recid>content: title potable water and methods of detecting impurities author baker m n medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water</md-title>
+<md-date>2000</md-date>
+<md-author>Majeed, Abdul</md-author>
+<md-description>&quot;Balochistan conservation strategy background paper&quot;--T.p</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water</md-title>
+<md-date>2000</md-date>
+<md-author>Majeed, Abdul</md-author>
+<md-description>&quot;Balochistan conservation strategy background paper&quot;--T.p</md-description>
+<md-medium>book</md-medium></location>
+<relevance>20202</relevance>
+<recid>content: title water author majeed abdul medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water</md-title>
+<md-date>2000</md-date>
+<md-author>Grant, Pamela</md-author>
+<md-description>Examines major environmental issues surrounding water, giving examples of attempts to solve global problems and sources for more information</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water</md-title>
+<md-date>2000</md-date>
+<md-author>Grant, Pamela</md-author>
+<md-description>Includes index</md-description>
+<md-description>Examines major environmental issues surrounding water, giving examples of attempts to solve global problems and sources for more information</md-description>
+<md-medium>book</md-medium></location>
+<relevance>18501</relevance>
+<recid>content: title water author grant pamela medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water law</md-title>
+<md-date>2000</md-date>
+<md-author>Fisher, D. E</md-author>
+<md-description>Includes index</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water law</md-title>
+<md-date>2000</md-date>
+<md-author>Fisher, D. E</md-author>
+<md-description>Includes index</md-description>
+<md-medium>book</md-medium></location>
+<relevance>18182</relevance>
+<recid>content: title water law author fisher d e medium book</recid>
+</hit>
+<hit>
+
+<md-title>A Primer on fresh water</md-title>
+<md-title-remainder>questions and answers</md-title-remainder>
+<md-date>2000</md-date>
+<md-description>Issued also in French under title: Notions élémentaires sur l&apos;eau douce : questions et réponses</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>A Primer on fresh water</md-title>
+<md-title-remainder>questions and answers</md-title-remainder>
+<md-date>2000</md-date>
+<md-description>Issued also in French under title: Notions élémentaires sur l&apos;eau douce : questions et réponses</md-description>
+<md-description>Includes index</md-description>
+<md-medium>book</md-medium></location>
+<relevance>17576</relevance>
+<recid>content: title a primer on fresh water medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water and water supplies</md-title>
+<md-date>1901</md-date>
+<md-author>Thresh, John Clough</md-author>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water and water supplies</md-title>
+<md-date>1901</md-date>
+<md-author>Thresh, John Clough</md-author>
+<md-medium>book</md-medium></location>
+<relevance>15152</relevance>
+<recid>content: title water and water supplies author thresh john clough medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water quality assessment of the State Water Project, 1996-97</md-title>
+<md-date>1999-2000</md-date>
+<md-description>&quot;September 1999.&quot;</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water quality assessment of the State Water Project, 1998-99</md-title>
+<md-date>2000</md-date>
+<md-description>Cover title</md-description>
+<md-description>&quot;July 2000.&quot;</md-description>
+<md-medium>book</md-medium></location>
+<location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water quality assessment of the State Water Project, 1996-97</md-title>
+<md-date>1999</md-date>
+<md-description>Cover title</md-description>
+<md-description>&quot;September 1999.&quot;</md-description>
+<md-medium>book</md-medium></location>
+<count>2</count>
+<relevance>15152</relevance>
+<recid>content: title water quality assessment of the state water project medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water-supply</md-title>
+<md-title-remainder>(Considered principally from a sanitary standpoint.)</md-title-remainder>
+<md-date>1896</md-date>
+<md-author>Mason, William Pitt</md-author>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water-supply</md-title>
+<md-title-remainder>(Considered principally from a sanitary standpoint.)</md-title-remainder>
+<md-date>1896</md-date>
+<md-author>Mason, William Pitt</md-author>
+<md-medium>book</md-medium></location>
+<relevance>15152</relevance>
+<recid>content: title water supply author mason william pitt medium book</recid>
+</hit>
+<hit>
+
+<md-title>The law of waters and water rights</md-title>
+<md-title-remainder>international, national, state, municipal, and individual, including irrigation, drainage, and municipal water supply</md-title-remainder>
+<md-date>1904</md-date>
+<md-author>Farnham, Henry P</md-author>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>The law of waters and water rights</md-title>
+<md-title-remainder>international, national, state, municipal, and individual, including irrigation, drainage, and municipal water supply</md-title-remainder>
+<md-date>1904</md-date>
+<md-author>Farnham, Henry P</md-author>
+<md-medium>book</md-medium></location>
+<relevance>14630</relevance>
+<recid>content: title the law of waters and water rights author farnham henry p medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water, in press, 1998</md-title>
+<md-title-remainder>an index of news items on water resources selected from leading news papers</md-title-remainder>
+<md-date>1998-1999</md-date>
+<md-description>With reference to India</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water, in press, 1998</md-title>
+<md-title-remainder>an index to news items on water resources selected from leading news papers</md-title-remainder>
+<md-date>1999</md-date>
+<md-description>Includes index</md-description>
+<md-medium>book</md-medium></location>
+<location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water in press, 1997</md-title>
+<md-title-remainder>an index of news items on water resources selected from leading news papers</md-title-remainder>
+<md-date>1998</md-date>
+<md-description>Includes index</md-description>
+<md-description>With reference to India</md-description>
+<md-medium>book</md-medium></location>
+<count>2</count>
+<relevance>13675</relevance>
+<recid>content: title water in press medium book</recid>
+</hit>
+<hit>
+
+<md-title>Regulations on the disposal of arsenic residuals from drinking water treatment plants</md-title>
+<md-date>2000</md-date>
+<md-description>&quot;EPA Contract 68-C7-0011, work assignment 0-38.&quot;</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Regulations on the disposal of arsenic residuals from drinking water treatment plants</md-title>
+<md-date>2000</md-date>
+<md-description>&quot;May 2000.&quot;</md-description>
+<md-description>&quot;EPA/600/R-00/025.&quot;</md-description>
+<md-description>&quot;EPA Contract 68-C7-0011, work assignment 0-38.&quot;</md-description>
+<md-medium>book</md-medium></location>
+<relevance>13636</relevance>
+<recid>content: title regulations on the disposal of arsenic residuals from drinking water treatment plants medium book</recid>
+</hit>
+<hit>
+
+<md-title>A guide to Montana water quality regulation</md-title>
+<md-date>1997</md-date>
+<md-author>Bryan, Michelle</md-author>
+<md-description>&quot;A joint publication of Legislative Environmental Policy Office, Environmental Quality Council [and] Montana University System, Water Center&quot;</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>A guide to Montana water quality regulation</md-title>
+<md-date>1997</md-date>
+<md-author>Bryan, Michelle</md-author>
+<md-description>&quot;A joint publication of Legislative Environmental Policy Office, Environmental Quality Council [and] Montana University System, Water Center&quot;</md-description>
+<md-medium>book</md-medium></location>
+<relevance>13199</relevance>
+<recid>content: title a guide to montana water quality regulation author bryan michelle medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water technology management</md-title>
+<md-date>2001</md-date>
+<md-description>Collection of articles with reference to India</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water technology management</md-title>
+<md-date>2001</md-date>
+<md-description>Collection of articles with reference to India</md-description>
+<md-medium>book</md-medium></location>
+<relevance>13131</relevance>
+<recid>content: title water technology management medium book</recid>
+</hit>
+<hit>
+
+<md-title>Aquatic habitat indicators and their application to water quality objectives within the Clean Water Act</md-title>
+<md-date>1999</md-date>
+<md-author>Bauer, Steve</md-author>
+<md-description>&quot;This document was developed for US Environmental Protection Agency, Region 10, Seattle Washington, with the Idaho Water Resources Institute, University of Idaho.&quot;</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Aquatic habitat indicators and their application to water quality objectives within the Clean Water Act</md-title>
+<md-date>1999</md-date>
+<md-author>Bauer, Steve</md-author>
+<md-description>&quot;This document was developed for US Environmental Protection Agency, Region 10, Seattle Washington, with the Idaho Water Resources Institute, University of Idaho.&quot;</md-description>
+<md-medium>book</md-medium></location>
+<relevance>13016</relevance>
+<recid>content: title aquatic habitat indicators and their application to water quality objectives within the clean water act author bauer steve medium book</recid>
+</hit>
+<hit>
+
+<md-title>An empirical analysis of water temperature and dissolved oxygen conditions in the Red Deer River</md-title>
+<md-date>1997</md-date>
+<md-author>Saffran, Karen Anita</md-author>
+<md-description>&quot;March 1997.&quot;</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>An empirical analysis of water temperature and dissolved oxygen conditions in the Red Deer River</md-title>
+<md-date>1997</md-date>
+<md-author>Saffran, Karen Anita</md-author>
+<md-description>&quot;March 1997.&quot;</md-description>
+<md-medium>book</md-medium></location>
+<relevance>12929</relevance>
+<recid>content: title an empirical analysis of water temperature and dissolved oxygen conditions in the red deer river author saffran karen anita medium book</recid>
+</hit>
+<hit>
+
+<md-title>Surface water quality monitoring procedures manual</md-title>
+<md-date>1999</md-date>
+<md-description>&quot;GI-252&quot;--Cover</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Surface water quality monitoring procedures manual</md-title>
+<md-date>1999</md-date>
+<md-description>&quot;June 1999.&quot;</md-description>
+<md-description>&quot;GI-252&quot;--Cover</md-description>
+<md-medium>book</md-medium></location>
+<relevance>12626</relevance>
+<recid>content: title surface water quality monitoring procedures manual medium book</recid>
+</hit>
+<hit>
+
+<md-title>International Conference on Management of Drinking Water Resources, Chennai, December 3-5, 1997</md-title>
+<md-title-remainder>proceedings</md-title-remainder>
+<md-date>1997</md-date>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>International Conference on Management of Drinking Water Resources, Chennai, December 3-5, 1997</md-title>
+<md-title-remainder>proceedings</md-title-remainder>
+<md-date>1997</md-date>
+<md-medium>book</md-medium></location>
+<relevance>12323</relevance>
+<recid>content: title international conference on management of drinking water resources chennai december medium book</recid>
+</hit>
+<hit>
+
+<md-title>Mercados e instituciones de aguas en Bolivia</md-title>
+<md-date>1998</md-date>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Mercados e instituciones de aguas en Bolivia</md-title>
+<md-date>1998</md-date>
+<md-medium>book</md-medium></location>
+<relevance>12121</relevance>
+<recid>content: title mercados e instituciones de aguas en bolivia medium book</recid>
+</hit>
+<hit>
+
+<md-title>Water law</md-title>
+<md-date>2000</md-date>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Water law</md-title>
+<md-date>2000</md-date>
+<md-medium>book</md-medium></location>
+<relevance>12121</relevance>
+<recid>content: title water law medium book</recid>
+</hit>
+</show>
\ No newline at end of file
diff --git a/test/test_solr_26.res b/test/test_solr_26.res
new file mode 100644 (file)
index 0000000..b709f6e
--- /dev/null
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<bytarget><status>OK</status>
+<target><id>LOC Solr Test</id>
+<name>LOC Solr Test</name>
+<hits>1995</hits>
+<diagnostic>0</diagnostic>
+<records>100</records>
+<state>Client_Idle</state>
+</target></bytarget>
\ No newline at end of file
diff --git a/test/test_solr_27.res b/test/test_solr_27.res
new file mode 100644 (file)
index 0000000..294fe36
--- /dev/null
@@ -0,0 +1,68 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<termlist><activeclients>0</activeclients>
+<list name="xtargets">
+<term>
+<id>LOC Solr Test</id>
+<name>LOC Solr Test</name>
+<frequency>1995</frequency>
+<state>Client_Idle</state>
+<diagnostic>0</diagnostic>
+</term>
+</list>
+<list name="subject">
+<term><name>Water-supply</name><frequency>185</frequency></term>
+<term><name>Water</name><frequency>169</frequency></term>
+<term><name>Groundwater</name><frequency>94</frequency></term>
+<term><name>Water resources development</name><frequency>93</frequency></term>
+<term><name>Water quality</name><frequency>87</frequency></term>
+<term><name>Mineral waters</name><frequency>52</frequency></term>
+<term><name>Water quality management</name><frequency>50</frequency></term>
+<term><name>United States</name><frequency>43</frequency></term>
+<term><name>Irrigation</name><frequency>33</frequency></term>
+<term><name>N.Y</name><frequency>28</frequency></term>
+<term><name>Hydraulic engineering</name><frequency>24</frequency></term>
+<term><name>Geology</name><frequency>23</frequency></term>
+<term><name>U.S</name><frequency>23</frequency></term>
+<term><name>Groundwater flow</name><frequency>22</frequency></term>
+<term><name>Birds</name><frequency>21</frequency></term>
+</list>
+<list name="author">
+<term><name>Waters, Clara Erskine Clement</name><frequency>9</frequency></term>
+<term><name>Waters, Henry F</name><frequency>8</frequency></term>
+<term><name>Moorman, J. J</name><frequency>7</frequency></term>
+<term><name>Waters, Thomas Franklin</name><frequency>6</frequency></term>
+<term><name>Basak, P</name><frequency>5</frequency></term>
+<term><name>Bergren, Lisa Tawn</name><frequency>5</frequency></term>
+<term><name>Kingsley, Charles</name><frequency>5</frequency></term>
+<term><name>Tyndall, John</name><frequency>5</frequency></term>
+<term><name>Baldwin, William J</name><frequency>4</frequency></term>
+<term><name>Holme, Charles</name><frequency>4</frequency></term>
+<term><name>James, E. J</name><frequency>4</frequency></term>
+<term><name>Nuttall, Thomas</name><frequency>4</frequency></term>
+<term><name>Walton, George Edward</name><frequency>4</frequency></term>
+<term><name>Wilkins, John H</name><frequency>4</frequency></term>
+<term><name>Arthur, Kay</name><frequency>3</frequency></term>
+</list>
+<list name="date">
+<term><name>2000</name><frequency>411</frequency></term>
+<term><name>1999</name><frequency>318</frequency></term>
+<term><name>1998</name><frequency>90</frequency></term>
+<term><name>2001</name><frequency>87</frequency></term>
+<term><name>1907</name><frequency>50</frequency></term>
+<term><name>1902</name><frequency>46</frequency></term>
+<term><name>1906</name><frequency>43</frequency></term>
+<term><name>1905</name><frequency>39</frequency></term>
+<term><name>1909</name><frequency>39</frequency></term>
+<term><name>1904</name><frequency>36</frequency></term>
+<term><name>1997</name><frequency>35</frequency></term>
+<term><name>1908</name><frequency>33</frequency></term>
+<term><name>1996</name><frequency>32</frequency></term>
+<term><name>1903</name><frequency>30</frequency></term>
+<term><name>1901</name><frequency>29</frequency></term>
+</list>
+<list name="medium">
+<term><name>book</name><frequency>1984</frequency></term>
+<term><name>web</name><frequency>8</frequency></term>
+<term><name>book (electronic)</name><frequency>3</frequency></term>
+</list>
+</termlist>
\ No newline at end of file
diff --git a/test/test_solr_28.res b/test/test_solr_28.res
new file mode 100644 (file)
index 0000000..ab63fe6
--- /dev/null
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<search><status>OK</status></search>
\ No newline at end of file
diff --git a/test/test_solr_29.res b/test/test_solr_29.res
new file mode 100644 (file)
index 0000000..00b1fd7
--- /dev/null
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<show><status>OK</status>
+<activeclients>0</activeclients>
+<merged>2</merged>
+<total>2</total>
+<start>0</start>
+<num>2</num>
+<hit>
+
+<md-title>The nitrogen permitting and trading plan for Long Island Sound</md-title>
+<md-date>2000</md-date>
+<md-description>&quot;In response to Special Act No. 99-6.&quot;</md-description>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>The nitrogen permitting and trading plan for Long Island Sound</md-title>
+<md-date>2000</md-date>
+<md-description>Title from cover</md-description>
+<md-description>&quot;January 2000.&quot;</md-description>
+<md-description>&quot;In response to Special Act No. 99-6.&quot;</md-description>
+<md-medium>book</md-medium></location>
+<relevance>300000</relevance>
+<recid>content: title the nitrogen permitting and trading plan for long island sound medium book</recid>
+</hit>
+<hit>
+
+<md-title>Report of the Water commissioners to the Common council of the city of Albany;</md-title>
+<md-date>1872</md-date>
+<md-medium>book</md-medium><location id="LOC Solr Test" name="LOC Solr Test">
+<md-title>Report of the Water commissioners to the Common council of the city of Albany;</md-title>
+<md-date>1872</md-date>
+<md-medium>book</md-medium></location>
+<relevance>192857</relevance>
+<recid>content: title report of the water commissioners to the common council of the city of albany medium book</recid>
+</hit>
+</show>
\ No newline at end of file
index 631044f..867c513 100644 (file)
@@ -1,4 +1,4 @@
-<!-- Solr target -->
+<!-- Solr target, settings 4-->
 <settings target="LOC Solr Test">
   <set name="pz:maxrecs" value="200" /> 
   <set name="pz:present_chunk" value="0"/>
diff --git a/test/test_solr_settings_5.xml b/test/test_solr_settings_5.xml
new file mode 100644 (file)
index 0000000..2aa611b
--- /dev/null
@@ -0,0 +1,5 @@
+<!-- Solr target, Settings 5 -->
+<settings target="LOC Solr Test">
+  <set name="pz:maxrecs" value="100" /> 
+  <set name="pz:present_chunk" value=""/>
+</settings>
index a362da1..8fe0a37 100644 (file)
   <!-- Result normalization settings -->
 
   <set name="pz:nativesyntax" value="iso2709"/>
-  <set name="pz:xslt" value="marc21_test.xsl"/>
+  <set name="pz:xslt">
+<xsl:stylesheet
+    version="1.0"
+    xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+    xmlns:pz="http://www.indexdata.com/pazpar2/1.0"
+    xmlns:marc="http://www.loc.gov/MARC21/slim">
+
+    <xsl:param name="test"/>
+  
+  <xsl:output indent="yes" method="xml" version="1.0" encoding="UTF-8"/>
+
+<!-- Extract metadata from MARC21/USMARC 
+      http://www.loc.gov/marc/bibliographic/ecbdhome.html
+-->  
+  
+  <xsl:template match="marc:record">
+    <xsl:variable name="title_medium" select="marc:datafield[@tag='245']/marc:subfield[@code='h']"/>
+    <xsl:variable name="journal_title" select="marc:datafield[@tag='773']/marc:subfield[@code='t']"/>
+    <xsl:variable name="electronic_location_url" select="marc:datafield[@tag='856']/marc:subfield[@code='u']"/>
+    <xsl:variable name="fulltext_a" select="marc:datafield[@tag='900']/marc:subfield[@code='a']"/>
+    <xsl:variable name="fulltext_b" select="marc:datafield[@tag='900']/marc:subfield[@code='b']"/>
+    <xsl:variable name="medium">
+      <xsl:choose>
+       <xsl:when test="$title_medium">
+         <xsl:value-of select="substring-after(substring-before($title_medium,']'),'[')"/>
+       </xsl:when>
+       <xsl:when test="$fulltext_a">
+         <xsl:text>electronic resource</xsl:text>
+       </xsl:when>
+       <xsl:when test="$fulltext_b">
+         <xsl:text>electronic resource</xsl:text>
+       </xsl:when>
+       <xsl:when test="$electronic_location_url">
+         <xsl:text>electronic resource</xsl:text>
+       </xsl:when>
+       <xsl:when test="$journal_title">
+         <xsl:text>article</xsl:text>
+       </xsl:when>
+       <xsl:otherwise>
+         <xsl:text>book</xsl:text>
+       </xsl:otherwise>
+      </xsl:choose>
+    </xsl:variable>
+
+    <pz:record>
+      <xsl:attribute name="mergekey">
+        <xsl:text>title </xsl:text>
+       <xsl:value-of select="marc:datafield[@tag='245']/marc:subfield[@code='a']"/>
+       <xsl:text> author </xsl:text>
+       <xsl:value-of select="marc:datafield[@tag='100']/marc:subfield[@code='a']"/>
+       <xsl:text> medium </xsl:text>
+       <xsl:value-of select="$medium"/>
+      </xsl:attribute>
+
+      <pz:metadata type="test-usersetting-2">
+        test-usersetting-2 data: 
+        <xsl:value-of select="$test"/>
+      </pz:metadata>
+
+      <xsl:for-each select="marc:controlfield[@tag='001']">
+        <pz:metadata type="id">
+          <xsl:value-of select="."/>
+        </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='010']">
+        <pz:metadata type="lccn">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='020']">
+        <pz:metadata type="isbn">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='022']">
+        <pz:metadata type="issn">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='027']">
+        <pz:metadata type="tech-rep-nr">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='100']">
+       <pz:metadata type="author">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+       <pz:metadata type="author-title">
+         <xsl:value-of select="marc:subfield[@code='c']"/>
+       </pz:metadata>
+       <pz:metadata type="author-date">
+         <xsl:value-of select="marc:subfield[@code='d']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='110']">
+       <pz:metadata type="corporate-name">
+           <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+       <pz:metadata type="corporate-location">
+           <xsl:value-of select="marc:subfield[@code='c']"/>
+       </pz:metadata>
+       <pz:metadata type="corporate-date">
+           <xsl:value-of select="marc:subfield[@code='d']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='111']">
+       <pz:metadata type="meeting-name">
+           <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+       <pz:metadata type="meeting-location">
+           <xsl:value-of select="marc:subfield[@code='c']"/>
+       </pz:metadata>
+       <pz:metadata type="meeting-date">
+           <xsl:value-of select="marc:subfield[@code='d']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='260']">
+       <pz:metadata type="date">
+           <xsl:value-of select="marc:subfield[@code='c']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='245']">
+        <pz:metadata type="title">
+          <xsl:value-of select="marc:subfield[@code='a']"/>
+        </pz:metadata>
+        <pz:metadata type="title-remainder">
+          <xsl:value-of select="marc:subfield[@code='b']"/>
+        </pz:metadata>
+        <pz:metadata type="title-responsibility">
+          <xsl:value-of select="marc:subfield[@code='c']"/>
+        </pz:metadata>
+        <pz:metadata type="title-dates">
+          <xsl:value-of select="marc:subfield[@code='f']"/>
+        </pz:metadata>
+        <pz:metadata type="title-medium">
+          <xsl:value-of select="marc:subfield[@code='h']"/>
+        </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='250']">
+       <pz:metadata type="edition">
+           <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='260']">
+        <pz:metadata type="publication-place">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+        <pz:metadata type="publication-name">
+         <xsl:value-of select="marc:subfield[@code='b']"/>
+       </pz:metadata>
+        <pz:metadata type="publication-date">
+         <xsl:value-of select="marc:subfield[@code='c']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='300']">
+       <pz:metadata type="physical-extent">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+       <pz:metadata type="physical-format">
+         <xsl:value-of select="marc:subfield[@code='b']"/>
+       </pz:metadata>
+       <pz:metadata type="physical-dimensions">
+         <xsl:value-of select="marc:subfield[@code='c']"/>
+       </pz:metadata>
+       <pz:metadata type="physical-accomp">
+         <xsl:value-of select="marc:subfield[@code='e']"/>
+       </pz:metadata>
+       <pz:metadata type="physical-unittype">
+         <xsl:value-of select="marc:subfield[@code='f']"/>
+       </pz:metadata>
+       <pz:metadata type="physical-unitsize">
+         <xsl:value-of select="marc:subfield[@code='g']"/>
+       </pz:metadata>
+       <pz:metadata type="physical-specified">
+         <xsl:value-of select="marc:subfield[@code='3']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='440']">
+       <pz:metadata type="series-title">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag &gt;= 500 and @tag &lt;= 599]
+                           [@tag != '506' and @tag != '530' and
+                           @tag != '540' and @tag != '546'
+                            and @tag != '522']">
+        <!-- The tag attribute below will be preserved -->
+       <pz:metadata type="description" tag="{@tag}">
+            <xsl:value-of select="*/text()"/>
+        </pz:metadata>
+      </xsl:for-each>
+      
+      <xsl:for-each select="marc:datafield[@tag='600' or @tag='610' or @tag='611' or @tag='630' or @tag='648' or @tag='650' or @tag='651' or @tag='653' or @tag='654' or @tag='655' or @tag='656' or @tag='657' or @tag='658' or @tag='662' or @tag='69X']">
+       <pz:metadata type="subject">
+         <xsl:value-of select="marc:subfield[@code='a']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='856']">
+       <pz:metadata type="electronic-url">
+         <xsl:value-of select="marc:subfield[@code='u']"/>
+       </pz:metadata>
+       <pz:metadata type="electronic-text">
+         <xsl:value-of select="marc:subfield[@code='y']"/>
+       </pz:metadata>
+       <pz:metadata type="electronic-note">
+         <xsl:value-of select="marc:subfield[@code='z']"/>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <xsl:for-each select="marc:datafield[@tag='773']">
+       <pz:metadata type="citation">
+         <xsl:for-each select="*">
+           <xsl:value-of select="normalize-space(.)"/>
+           <xsl:text> </xsl:text>
+         </xsl:for-each>
+       </pz:metadata>
+      </xsl:for-each>
+
+      <pz:metadata type="medium">
+       <xsl:value-of select="$medium"/>
+      </pz:metadata>
+      
+      <xsl:if test="$fulltext_a">
+       <pz:metadata type="fulltext">
+         <xsl:value-of select="$fulltext_a"/>
+       </pz:metadata>
+      </xsl:if>
+
+      <xsl:if test="$fulltext_b">
+       <pz:metadata type="fulltext">
+         <xsl:value-of select="$fulltext_b"/>
+       </pz:metadata>
+      </xsl:if>
+    </pz:record>
+  </xsl:template>
+</xsl:stylesheet>
+  </set>
   
   <set name="pz:apdulog" value="1"/>
   <set name="pz:pqf_strftime" value="@or %% %Y"/>