+*/
+
+#include <assert.h>
+#include <yaz/wrbuf.h>
+#include "index.h"
+
+WRBUF zebra_mk_ord_str(int ord, const char *str)
+{
+ char pref[20];
+ WRBUF w = wrbuf_alloc();
+ int len;
+
+ assert(ord >= 0);
+
+ len = key_SU_encode(ord, pref);
+
+ wrbuf_write(w, pref, len);
+ wrbuf_puts(w, str);
+ return w;
+}
+
+char *dict_lookup_ord(Dict d, int ord, const char *str)
+{
+ WRBUF w = zebra_mk_ord_str(ord, str);
+ char *rinfo = dict_lookup(d, wrbuf_cstr(w));
+ wrbuf_destroy(w);
+ return rinfo;
+}
+
+int dict_insert_ord(Dict d, int ord, const char *p,
+ int userlen, void *userinfo)