X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=doc%2Frecordmodel-domxml.xml;fp=doc%2Frecordmodel-domxml.xml;h=1dd8559639c6b509f3dd919bea6d26e87a5b968b;hb=271266c6e2dfeef76ba5724848e435c441d671e7;hp=a9b85db7d726fb7eb9b50cc5679cf01f240fd8f2;hpb=14ad407ad29aa99585b84f7606508a7bec752019;p=idzebra-moved-to-github.git diff --git a/doc/recordmodel-domxml.xml b/doc/recordmodel-domxml.xml index a9b85db..1dd8559 100644 --- a/doc/recordmodel-domxml.xml +++ b/doc/recordmodel-domxml.xml @@ -1,7 +1,7 @@ - + &dom; &xml; Record Model and Filter Module - + The record model described in this chapter applies to the fundamental, structured &xml; @@ -602,9 +602,109 @@ ]]> + + + +
+ &dom; Indexing &marcxml; + + The &dom; filter allows indexing of both binary &marc; records + and &marcxml; records, depending on it's configuration. + A typical &marcxml; record might look like this: + + + 42 + 00366nam 22001698a 4500 + 11224466 + DLC + 00000000000000.0 + 910710c19910701nju 00010 eng + + 11224466 + + + DLC + DLC + + + 123-xyz + + + Jack Collins + + + How to program a computer + + + Penguin + + + 8710 + + + p. cm. + + + ]]> + + + + + It is easily possible to make string manipulation in the &dom; + filter. For example, if you want to drop some leading articles + in the indexing of sort fields, you might want to pick out the + &marcxml; indicator attributes to chop of leading substrings. If + the above &xml; example would have an indicator + ind2="8" in the title field + 245, i.e. + + + How to program a computer + + ]]> + + one could write a template taking into account this information + to chop the first 8 characters from the + sorting index title:s like this: + + + + + 0 + + + + + + + + + + + + + + ]]> + + The output of the above &marcxml; and &xslt; excerpt would then be: + + How to program a computer + program a computer + ]]> + + and the record would be sorted in the title index under 'P', not 'H'. + +
+ + +
+ &dom; Indexing Wizardry - Notice also, - that the names and types of the indexes can be defined in the + The names and types of the indexes can be defined in the indexing &xslt; stylesheet dynamically according to content in the original &xml; records, which has opportunities for great power and wizardry as well as grande