开发者

Want to change my.ini file in sql for some session only

开发者 https://www.devze.com 2023-01-29 14:07 出处:网络
I am using MATCH(col1,col2) AGAINST(\"text\") query to search things fastly. But due tto its limitation of full stop words. I need to change my.ini file. I need to add this much of code in my.ini file

I am using MATCH(col1,col2) AGAINST("text") query to search things fastly. But due tto its limitation of full stop words. I need to change my.ini file. I need to add this much of code in my.ini file.

[mysqld]
ft_min_word_len = "1"
ft_stopword_file =""

I want to add commands for my application only. Because it may happens my.ini file will be used by many other application. I want some php script with particular sess开发者_运维问答ion.


You won't be able to set this dynamically at runtime, as fulltext settings can be changed before starting the server.

As far I see you will need a dedicated server instance for this site, you can do that by starting on some other port than the default one.

And you can pass the param at the command line when starting the server

mysqld --ft_min_word_len=1 --ft_stopword_file=''

Please note that once you change the fulltext system variable you need to rebuild all your fulltext indexes you want to affect.

0

精彩评论

暂无评论...
验证码 换一张
取 消