Hello,
In my database i have table t_person with columns first_name and
last_name. At this table i created full text lucene index:

CALL FTL_CREATE_INDEX('PUBLIC', 'T_PERSON', NULL);

Now, it's easy to search some person:

select *
from ftl_search_data('joh*', 0, 0) a
where a.table='T_PERSON'

But in frontend of application there are also two fields First Name
and Last Name. User should has possibility to look person only by
first name, only by last name or by first and last name. How can i
resolve this problem, i can't write query:

select *
from ftl_search_data('joh*', 0, 0) a
where a.table='T_PERSON'
AND A.COLUMN='FIRST_NAME'

or something like this. Results from this index are mixed, together
are show result for first_name and last_name. For example person has
last name John and where application user is looking for person with
first_name='John'  will find this person too, but shouldn't.

PS. Now my article about h2databse is available to download for free
at http://lpmagazine.org/pl/magazine/1039-wirtualizacja (registration
is required).

Best regards
sw


-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to