#include <yaz/srw.h>
#include <yaz/matchstr.h>
#include <yaz/yaz-iconv.h>
+#include <yaz/log.h>
#include "sru-p.h"
record->recordData_buf = odr_malloc(o, buf->use + 1);
memcpy(record->recordData_buf, buf->content, buf->use);
record->recordData_buf[buf->use] = '\0';
- record->recordPosition = odr_intdup(o, start + offset);
+ // TODO Solve the real problem: Making the recordPosition 1-based due to "funny" code in zoom-sru
+ record->recordPosition = odr_intdup(o, start + offset + 1);
xmlBufferFree(buf);
#endif
}
-int yaz_solr_encode(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu,
- ODR encode, const char *charset)
+int yaz_solr_encode_request(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu,
+ ODR encode, const char *charset)
{
const char *solr_op = 0;
char *name[30], *value[30];
}
yaz_add_name_value_int(encode, name, value, &i,
"rows", srw_pdu->u.request->maximumRecords);
+ yaz_add_name_value_str(encode, name, value, &i,
+ "fl", srw_pdu->u.request->recordSchema);
break;
default:
return -1;