QuickSearch again (or still)

Found a bug? Tell us!!
Post Reply
Emkay_

QuickSearch again (or still)

Post by Emkay_ »

Hi there,
I just discovered this great app and yes ... it's about the (Quick)Search function again. :)
I'm aware that this has been an issue several times before but none of the suggested methods helped me fixing this. I'm no SQL wizard so I didn't really get the message about Index-creation, indexing in different MySQL versions etc.

-------------------------------
My Configuration:
-------------------------------
Serendipity 0.7.1
MySQL 3.23.57
PHP Version 4.3.10
on a shared host

-------------------------------
My Problem:
-------------------------------
(1.) Default installation:
-------------------------------
- Search for non-existent terms:
"1 entry found - no entry shown"
- Search for existent terms:
(same)

-------------------------------
(2.) After running the suggested sql command (viewtopic.php?t=508) in phpMyAdmin
(CREATE FULLTEXT INDEX entry_idx on MYPREFIX_entries (title,body,extended);)
-------------------------------
now running the same searches as before gets me a ...
- Search for non-existent terms:
"no entry found"
- Search for existent terms:
(same)


Now the indexes in MYPREFIX_entries look like this:

Code: Select all

Indexes:
Keyname		Type		Cardinality		Field
PRIMARY		PRIMARY		1				id
entry_idx	FULLTEXT	None			title
										body 		1
										extended	1
Q: is this the way it's supposed to look like? Anything wrong with this or any (new) thoughts about this issue?

Thanks
Emkay
[/quote][/code]
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: QuickSearch again (or still)

Post by garvinhicking »

You need to insert a few entries into your table before the fulltext search works. Also pay attention to not search for dummy entries with only few words, as those will be interpreted as stop-words.

Regards,
garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Emkay_

Post by Emkay_ »

Ah, thanks for the quick reply. Will try that before I go on complaining ... ;)

But what are
stop-words
and what do you mean by
not search for dummy entries with only few words
?

thanks
Emkay_

Post by Emkay_ »

*Update*

added a few entries and after making a few searches it works.
Multi string searches as well or single term searches.
Don't as me why... ( ask Garvin :lol: )

So no more complaints but I join the praising choir of happy S9y users and say:

Thank you!

PS:
again, for future knowledge:
all I did was running the ...

Code: Select all

CREATE FULLTEXT INDEX entry_idx on MYPREFIX_entries (title,body,extended);

... query in phpMyAdmin.
(where 'MYPREFIX' is the table-prefix you chose during the install process. If you didn't change the default, it's 'serendipity_entries', not 'MYPREFIX_entries')
garvinhicking
Core Developer
Posts: 30022
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Post by garvinhicking »

Stop-words were just words like "and", "or", "with" and so on. Common words which are usually not searched for.

MySQL seems to build up an index database only after a certain amount of entries/characters has been reached, so that's why it won't work instantly.

But now that everything is working: Have fun! :)

Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Post Reply