1
nayeem
criteriaCompo
  • 2004/6/29 12:23

  • nayeem

  • Just popping in

  • Posts: 44

  • Since: 2004/1/3 1


does anyone know if there is a way to pass a where clause to the criteriaCompo object, eg i want to include a fulltext condition :
where match(field1field2against "value"



thanks

nayeem

2
Mithrandir
Re: criteriaCompo

a CriteriaCompo object consists of Criteria objects - which is usually what comes after the WHERE in the SQL statement.

I'm not sure that I understand your question (not much of a fulltext person myself) but isn't it possible to use AND and ORs in your match(field1, field2)?

e.g.
WHERE field1 = "value" AND/OR field2 = "value"

3
nayeem
Re: criteriaCompo
  • 2004/6/29 12:54

  • nayeem

  • Just popping in

  • Posts: 44

  • Since: 2004/1/3 1


AND/OR wont work as they wont look inside the field, and it lacks many of the features of MySQL fulltext search. have a look at MySQL manualfor details on the fulltext. it has all standard features such as boolean, wildcards, and more.

I think for now I will just subclass the criteria class so that theres a seperate facility for adding and rendering fulltext search queries.

if you like I can post a copy of the subclass for some review since I am sure having a facility for doing fulltext search would be very convenient for XOOPS users.

nsm

4
Mithrandir
Re: criteriaCompo

Would be very useful, thank you.

a CriteriaFulltext class would be excellent

5
nayeem
Re: criteriaCompo
  • 2004/7/2 15:36

  • nayeem

  • Just popping in

  • Posts: 44

  • Since: 2004/1/3 1


Please find the files below. Dont have a permenant place myself so might be better if someone could copy this to a safer place :
criteriaFulltext

look forward to hearing about the review on this!

nayeem
[also a modified criteria class is included with added functionalities to give fulltext relevancy results. no existing code has been changed on it, only 2 methods and one memeber has been added to the class.]

Login

Who's Online

148 user(s) are online (90 user(s) are browsing Support Forums)


Members: 0


Guests: 148


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits