different language fields in the same model: is this possible?

4 views
Skip to first unread message

elpaso

unread,
Nov 21, 2009, 3:47:45 PM11/21/09
to Djapian Users
Hi,

I just discovered djapian, having worked with xapian in PHP in the
past I would love to use it in django too.

Just one question before diving into djapian: in my models I have some
language specific fields:

title_en
title_de
description_en
description_de

I would like to use a different stemming for these fields, is this
possible? I read about "multi" but it seems to use a function that
will return the language for the whole model and not for specific
fields.

Perhaps what I intend to do is not difficult to implement, but I would
like to hear something from who has more experience with djapian
before I start looking at the code.

Alex Koshelev

unread,
Nov 23, 2009, 5:23:05 PM11/23/09
to djapia...@googlegroups.com
Hi, elpaso!

I can give you an advise to use separate Indexers for distinct languages. In each Indexer definition have only fields specific for one language. Then you can search against them independently or together using CompositeIndexer.

Hope this helps!

---
Alex Koshelev



--

You received this message because you are subscribed to the Google Groups "Djapian Users" group.
To post to this group, send email to djapia...@googlegroups.com.
To unsubscribe from this group, send email to djapian-user...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/djapian-users?hl=.



Reply all
Reply to author
Forward
0 new messages