Hi Hoss

Thanks again for your attention.

Looks like after your last instructions I thought the same way as you :)

What I did yesterday:
1. Created the schema with the fields with language variations (created as
concrete fields anyway because in this case, using dynamic it wouldn't be
better for me):
    - defined field types: txt_en, txt_fr (with proper analyzers for each
language)
    - created fields title_en, title_fr (in its respective field types)
    - created a field title (that receives a copy of title_en and title_fr -
as they are exclusive, they won't override each other)
  
2. Created two dismax RequestHandlers, one per language. So the only thing
my client has to change when searching for an specific language is the "qt"
parameter.

So far it sounds good for my needs, now I'm going to try if my other
features still work (I'm worried about highlighting as I'm going to return a
different field)...

I'll come back to you with my results.

Regards,
Daniel


On 19/6/07 19:19, "Chris Hostetter" <[EMAIL PROTECTED]> wrote:

> 
> : range wouldn't be a problem in this case. The real issue I can see in this
> : approach, is related to Analyzers... How to make them deal with different
> : languages properly using one Solr instance with the same set of fields being
> : used by documents in different languages....
> 
> i would still use the same type of schema i suggested before ... one
> fieldtype per langauge and dynamic fields per language ... it's just that
> now you don't bother indexing text in both the english_title and
> french_title fields ... you use one or the other depending on what the
> langauge of this particular translation is, just as you guessed...
> 
> : Looks like my best alternative then is using dynamic fields having then a
> : set of fields for each language. But anyway I think I'll still need a way to
> : apply different analyzers at query time so I can deal with each language
> : details. Is it correct?
> 
> No, you just need your client to query the right field based on the
> langauge ... if the end user wants to search for "playa" in all "spanish"
> documents your client code should query for something
> like "spanish_title:playa^3 spanish_body:playa" ... you could even have a
> dismax handler instance configured per language to make this transparent
> to the client...
> 
>       q=playa&qt=spanish
> 
> ...since you know only have one language per "document" the reponse docs
> your client gets back are even easier to deal with, becuase you can have a
> single stored field for each conceptual field for display purposes using
> the canonical name ... the client can display the "title" field and hte
> "author" field and not have to know/remember that the search is in
> spanish.
> 
> 
> 
> -Hoss
> 


http://www.bbc.co.uk/
This e-mail (and any attachments) is confidential and may contain personal 
views which are not the views of the BBC unless specifically stated.
If you have received it in error, please delete it from your system.
Do not use, copy or disclose the information in any way nor act in reliance on 
it and notify the sender immediately.
Please note that the BBC monitors e-mails sent or received.
Further communication will signify your consent to this.
                                        

Reply via email to