You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-dev@xml.apache.org by 박남규 <pa...@hotmail.com> on 2002/07/16 04:56:11 UTC
Add Collection Indexer problem
Hi.
Since query costs more than 4 seconds , I want to create indexer in some collection. I see this contents in xindice home.
------------(from http://xml.apache.org/xindice/AdministratorsGuide.html)--------------
xindiceadmin add_collection_indexer -c /db/data/catalog -n idindex -p '*'
xindiceadmin add_collection_indexer -c /db/data/catalog -n idindex -p '*@*'
--------------------------------------------------------------------------------------------------------------------
But I failed to add indexer by above ways. There was no error and the result of command displayed help of 'xindiceadmin' command.
So, I did add indexer by using add_indexer like this.
--------------------------------------------------------------------------------------------------------------------
./xindiceadmin add_indexer -c /db/ProgressDoc/CompleteDoc -n completeindex -p *
./xindiceadmin add_indexer -c /db/ProgressDoc/CompleteDoc -n completeindex2 -p *@*
--------------------------------------------------------------------------------------------------------------------
Two indexer were created. But there was no affects about time. Also, XPathQueryService.query() got no data from db(It must get 15 documents at least)
How I creates indexer?
Regards for answer.
※ PS :
1. There are 50 documents in CompleteDoc collection.
2. XQuery is like this :
/pubdoc[boolean(//refapprove[userid='admin']) or boolean(//@order[../id='admin' and (../@status='complete' or ../@status='pending' and (../@kind='bypass' or ../@kind='post')))])]
3. Document Format is like this :
<?xml version="1.0" encoding="UTF-8"?>
<pubdoc type="report">
<processinfo currorder="2" view="y">
<docnumber>2002-001-000019</docnumber>
<doctitle>???</doctitle>
<date>20020625</date>
<draftinfo>
<dockind type="select" order="1">???I</dockind>
<keepyear type="select" order="1">1?</keepyear>
</draftinfo>
</processinfo>
<sendinfo>
<chargeinfo>
<department partcode="001">(?)???</department>
<charge>?????</charge>
</chargeinfo>
</sendinfo>
<approvalinfo>
<approval kind="normal" order="1" status="complete" retrieval="all" seto
der="4">
<id>admin</id>
<position>??</position>
<name>?????</name>
<sign>
<img src="/servlet/ApprovalSign?userid=admin&type=normal" al
=""/>
</sign>
<date>20020625</date>
<commentinfo position="" name="" date="20020625">test</commentinfo>
<unitmodify setline="y" modunit="y" setcomment="y" edit="n" readonly
"n"/>
</approval>
<approval kind="normal" order="2" status="pending" retrieval="all" setor
er="0">
<id>admin</id>
<position>??</position>
<name>?????</name>
<sign>
<img src="" alt=""/>
</sign>
<date/>
<commentinfo position="" name="" date=""/>
<unitmodify setline="n" modunit="y" setcomment="y" edit="n" readonly
"n"/>
</approval>
<approval kind="normal" order="3" status="pending" retrieval="all" setor
er="0">
<id>choongcl</id>
<position>??</position>
<name>???</name>
<sign>
<img src="" alt=""/>
</sign>
<date/>
<commentinfo position="" name="" date=""/>
<unitmodify setline="n" modunit="y" setcomment="y" edit="n" readonly
"n"/>
</approval>
<approval kind="normal" order="final" status="pending" retrieval="all" s
torder="0">
<id>TomcatGuru</id>
<position>??</position>
<name>???</name>
<sign>
<img src="" alt=""/>
</sign>
<date/>
<commentinfo position="" name="" date=""/>
<unitmodify setline="n" modunit="n" setcomment="y" edit="n" readonly
="n"/>
</approval>
<bulletininfo>
<bulletin when="4">
<beforeapprove>
<from/>
<to/>
</beforeapprove>
<afterapprove>
<from/>
<to/>
</afterapprove>
<refapprove/>
</bulletin>
</bulletininfo>
</approvalinfo>
<content>
<title>test</title>
<body>test</body>
</content>
<attachinfo>
</attachinfo>
<xslpath>
<collname>DocStorage/XSLT/NormalDoc</collname>
<dockey>Report</dockey>
</xslpath>
</pubdoc>