/*
- * Copyright (c) 2002-2003, Index Data.
+ * Copyright (c) 2002-2004, Index Data.
* See the file LICENSE for details.
*
- * $Id: srwutil.c,v 1.3 2004-01-05 09:34:42 adam Exp $
+ * $Id: srwutil.c,v 1.6 2004-01-07 20:36:44 adam Exp $
*/
#include <yaz/srw.h>
const char *operation = 0;
char *query = 0;
char *pQuery = 0;
+ char *stylesheet = 0;
if (charset)
*charset = 0;
query = yaz_uri_val(p1, "query", decode);
pQuery = yaz_uri_val(p1, "pQuery", decode);
operation = yaz_uri_val(p1, "operation", decode);
+ stylesheet = yaz_uri_val(p1, "stylesheet", decode);
if (!operation)
operation = "explain";
if ((operation && !strcmp(operation, "searchRetrieve"))
}
sr->u.request->recordSchema = yaz_uri_val(p1, "recordSchema", decode);
sr->u.request->recordPacking = yaz_uri_val(p1, "recordPacking", decode);
+ sr->u.request->stylesheet = stylesheet;
+
if (!sr->u.request->recordPacking)
sr->u.request->recordPacking = "xml";
yaz_uri_val_int(p1, "maximumRecords", decode,
sr->u.explain_request->recordPacking = "xml";
sr->u.explain_request->database = db;
+ sr->u.explain_request->stylesheet = stylesheet;
+
(*soap_package) = odr_malloc(decode, sizeof(**soap_package));
(*soap_package)->which = Z_SOAP_generic;
odr_malloc(o, sizeof(*sr->u.explain_request));
sr->u.explain_request->recordPacking = 0;
sr->u.explain_request->database = 0;
+ sr->u.explain_request->stylesheet = 0;
break;
case Z_SRW_explain_response:
sr->u.explain_response = (Z_SRW_explainResponse *)
{2, "System temporarily unavailable"},
{3, "Authentication error"},
/* Diagnostics Relating to CQL */
-{10, "Illegal query"},
-{11, "Unsupported query type (XCQL vs CQL)"},
+{10, "Query syntax error"},
+{11, "Unsupported query type"},
{12, "Too many characters in query"},
{13, "Unbalanced or illegal use of parentheses"},
{14, "Unbalanced or illegal use of quotes"},
7, 30,
8, 32,
9, 29,
+ 108, 10, /* Malformed query : Syntax error */
10, 10,
11, 12,
11, 23,
20, 56,
21, 52,
22, 50,
- 23, 1, /* bad map */
- 24, 63, /* bad map */
- 25, 63, /* bad map */
- 26, 63, /* bad map */
+ 23, 3,
+ 24, 66,
+ 25, 66,
+ 26, 66,
27, 51,
28, 52,
29, 52,