Hello all i have two questions about the metadata search
1) The first question is about the accentuated text.
If my metadata contain the work “juvénile” the search engine is unable to
find it.
To understand what happen i do a little modification on the Search.java.
context.info("Title '" + title.getText() + "'.");
context.info("Abstract '" + abstr.getText() + "'.");
context.info("Any '" + any.getText() + "'.");
if (title != null)
title.setText(MainUtil.splitWord(title.getText()));
if (abstr != null)
abstr.setText(MainUtil.splitWord(abstr.getText()));
if (any != null)
any.setText(MainUtil.splitWord(any.getText()));
context.info("Title '" + title.getText() + "'.");
context.info("Abstract '" + abstr.getText() + "'.");
context.info("Any '" + any.getText() + "'.");
After as example if i do a search criteria like that :
What : é è à
Title : é è à
Abstract : é è à
I can see that on the jeeve log.
2007-11-30 09:36:37,893 INFO [jeeves.request] -
2007-11-30 09:36:37,894 INFO [jeeves.request] - HTML Request (from
147.100.18.115) : /geonetwork/srv/en/main.search.embedded
2007-11-30 09:36:37,894 DEBUG [jeeves.request] - Method : GET
2007-11-30 09:36:37,894 DEBUG [jeeves.request] - Content type : null
2007-11-30 09:36:37,894 DEBUG [jeeves.request] - Accept :
text/javascript, text/html, application/xml, text/xml, */*
2007-11-30 09:36:37,895 INFO [jeeves.service] - Dispatching :
main.search.embedded
2007-11-30 09:36:37,895 DEBUG [jeeves.service] - -> parameters are :
<request>
<relation>overlaps</relation>
<attrset>geo</attrset>
<paper>off</paper>
<similarity>.8</similarity>
<southBL>-90</southBL>
<eastBL>180</eastBL>
<any>é è à </any>
<westBL>-180</westBL>
<abstract>é è à </abstract>
<title>é è à </title>
<northBL>90</northBL>
<digital>off</digital>
<hitsPerPage>10</hitsPerPage>
</request>
2007-11-30 09:36:37,895 INFO [jeeves.webapp.main.search.embedded] -
Returning search data
2007-11-30 09:36:37,896 INFO [jeeves.webapp.main.search.embedded] - title
'é è à '.
2007-11-30 09:36:37,896 INFO [jeeves.webapp.main.search.embedded] -
abstract 'é è à '.
2007-11-30 09:36:37,896 INFO [jeeves.webapp.main.search.embedded] - any 'é
è à '.
2007-11-30 09:36:37,914 INFO [jeeves.webapp.main.search.embedded] - title '
ã ã ã'.
2007-11-30 09:36:37,915 INFO [jeeves.webapp.main.search.embedded] -
abstract ' ã ã ã'.
2007-11-30 09:36:37,915 INFO [jeeves.webapp.main.search.embedded] - any ' ã
ã ã'.
2007-11-30 09:36:37,915 INFO [jeeves.webapp.main.search.embedded] -
Creating searchers
2007-11-30 09:36:37,916 DEBUG [geonetwork.search] - CRITERIA:
<request>
<relation>overlaps</relation>
<attrset>geo</attrset>
<paper>off</paper>
<similarity>.8</similarity>
<southBL>-90</southBL>
<eastBL>180</eastBL>
<any>ã ã ã</any>
<westBL>-180</westBL>
<abstract>ã ã ã</abstract>
<title>ã ã ã</title>
<northBL>90</northBL>
<digital>off</digital>
<hitsPerPage>10</hitsPerPage>
<group>1</group>
</request>
my “é è à” have been received as “é è Ô and after have been transformed
in “ã ã ã”, i do not understand why ?
My internet client is Mozilla firefox and i use the UTF 8.
I know that in English there is no accentuation, so maybe you haven't seen
that problem ?
2) The second question is about the search criteria :
In your help you said that it is possible to specify search criterias
between element like :
string1 and string2: search metadata having both "string1" and "string2" in
field
string1 or string2: search metadata having either 'string1' or "string2" in
field
string1 not string2: search metadata having "string1" but not "string2" in
field
After some try i have the feeling that do placing the “and” or the “or”
clause do not change anything
the parameters send to main.search.embedded are looking the same :
A ) what ?: inventaire contrat
<request>
<northBL>90</northBL>
<southBL>-90</southBL>
<eastBL>180</eastBL>
<relation>overlaps</relation>
<attrset>geo</attrset>
<any>inventaire contrat</any>
<westBL>-180</westBL>
<group>3</group>
<group>2</group>
<group>0</group>
<group>4</group>
<group>1</group>
<owner>1</owner>
<isAdmin>true</isAdmin>
</request>
<BooleanQuery>
<BooleanClause prohibited="false" required="true">
<TermQuery txt="inventaire" fld="any" />
</BooleanClause>
<BooleanClause prohibited="false" required="true">
<TermQuery txt="contrat" fld="any" />
</BooleanClause>
</BooleanQuery>
B ) what ?: "inventaire" and "contrat"
<request>
<northBL>90</northBL>
<southBL>-90</southBL>
<eastBL>180</eastBL>
<relation>overlaps</relation>
<attrset>geo</attrset>
<any>inventaire contrat</any>
<westBL>-180</westBL>
<group>3</group>
<group>2</group>
<group>0</group>
<group>4</group>
<group>1</group>
<owner>1</owner>
<isAdmin>true</isAdmin>
</request>
<BooleanQuery>
<BooleanClause prohibited="false" required="true">
<TermQuery txt="inventaire" fld="any" />
</BooleanClause>
<BooleanClause prohibited="false" required="true">
<TermQuery txt="contrat" fld="any" />
</BooleanClause>
</BooleanQuery>
C) what ?: "inventaire" or "contrat"
<request>
<northBL>90</northBL>
<southBL>-90</southBL>
<eastBL>180</eastBL>
<relation>overlaps</relation>
<attrset>geo</attrset>
<any>inventaire contrat</any>
<westBL>-180</westBL>
<group>3</group>
<group>2</group>
<group>0</group>
<group>4</group>
<group>1</group>
<owner>1</owner>
<isAdmin>true</isAdmin>
</request>
<BooleanClause prohibited="false" required="true">
<BooleanQuery>
<BooleanClause prohibited="false" required="true">
<TermQuery txt="inventaire" fld="any" />
</BooleanClause>
<BooleanClause prohibited="false" required="true">
<TermQuery txt="contrat" fld="any" />
</BooleanClause>
</BooleanQuery>
</BooleanClause>
Is it a change on the 2.1 release is it because of lucene constraints ?
Thank you very much
Fabien Bachraty
--
View this message in context: http://www.nabble.com/Question-about-metadata-search-tf4935597s18419.html#a14127260
Sent from the geonetwork-users mailing list archive at Nabble.com.