473,326 Members | 2,081 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Tsearch case sensitive with dotted search terms.


Hi,

I think when search terms have "."s in them they become case sensitive
in tsearch searches. How can we make them insensitive?

Regds
Mallah.


tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'a.u.m&logistics';
+------------------------------------+--------------------------------------+
| co_name |
co_name_index |
+------------------------------------+--------------------------------------+
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (INDIA) PVT. LTD. | 'ltd' 'pvt' 'a.u.m' 'india'
'logist' |
+------------------------------------+--------------------------------------+
(3 rows)

Time: 404.543 ms
tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'a.u.m&LOGISTICS';
+------------------------------------+--------------------------------------+
| co_name |
co_name_index |
+------------------------------------+--------------------------------------+
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (INDIA) PVT. LTD. | 'ltd' 'pvt' 'a.u.m' 'india'
'logist' |
+------------------------------------+--------------------------------------+
(3 rows)

Time: 425.697 ms
tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'A.U.M&LOGISTICS';
+---------+---------------+
| co_name | co_name_index |
+---------+---------------+
+---------+---------------+
(0 rows)
Nov 23 '05 #1
2 1404
Use tsearch2, tsearch is marked as obsolet :)
More serious: apply attached patch, recompile and reinstall contrib/tsearch
module. Patch commited to 7.3,7.4 and 7.5 branches, it fix asymetrical lexeme
processing for text and query.

Rajesh Kumar Mallah wrote:

Hi,

I think when search terms have "."s in them they become case sensitive
in tsearch searches. How can we make them insensitive?

Regds
Mallah.


tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'a.u.m&logistics';
+------------------------------------+--------------------------------------+
| co_name |
co_name_index |
+------------------------------------+--------------------------------------+
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (INDIA) PVT. LTD. | 'ltd' 'pvt' 'a.u.m' 'india'
'logist' |
+------------------------------------+--------------------------------------+
(3 rows)

Time: 404.543 ms
tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'a.u.m&LOGISTICS';
+------------------------------------+--------------------------------------+
| co_name |
co_name_index |
+------------------------------------+--------------------------------------+
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (INDIA) PVT. LTD. | 'ltd' 'pvt' 'a.u.m' 'india'
'logist' |
+------------------------------------+--------------------------------------+
(3 rows)

Time: 425.697 ms
tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'A.U.M&LOGISTICS';
+---------+---------------+
| co_name | co_name_index |
+---------+---------------+
+---------+---------------+
(0 rows)


--
Teodor Sigaev E-mail: te****@sigaev.ru
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Nov 23 '05 #2
Use tsearch2, tsearch is marked as obsolet :)
More serious: apply attached patch, recompile and reinstall contrib/tsearch
module. Patch commited to 7.3,7.4 and 7.5 branches, it fix asymetrical lexeme
processing for text and query.

Rajesh Kumar Mallah wrote:

Hi,

I think when search terms have "."s in them they become case sensitive
in tsearch searches. How can we make them insensitive?

Regds
Mallah.


tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'a.u.m&logistics';
+------------------------------------+--------------------------------------+
| co_name |
co_name_index |
+------------------------------------+--------------------------------------+
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (INDIA) PVT. LTD. | 'ltd' 'pvt' 'a.u.m' 'india'
'logist' |
+------------------------------------+--------------------------------------+
(3 rows)

Time: 404.543 ms
tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'a.u.m&LOGISTICS';
+------------------------------------+--------------------------------------+
| co_name |
co_name_index |
+------------------------------------+--------------------------------------+
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (I) PVT. LTD. | 'ltd' 'pvt' 'a.u.m'
'logist' |
| A.U.M. LOGISTICS (INDIA) PVT. LTD. | 'ltd' 'pvt' 'a.u.m' 'india'
'logist' |
+------------------------------------+--------------------------------------+
(3 rows)

Time: 425.697 ms
tradein_clients=# SELECT co_name , co_name_index from iid_listing where
co_name_index ## 'A.U.M&LOGISTICS';
+---------+---------------+
| co_name | co_name_index |
+---------+---------------+
+---------+---------------+
(0 rows)


--
Teodor Sigaev E-mail: te****@sigaev.ru
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Nov 23 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: chelleybabyger | last post by:
Below is my sql search code in my asp page. But my search seems to be case sensitive. How can i modify it to make it not case sensitive? Thanks <% sqlString = "SELECT product_image, product_name,...
2
by: Barbara White | last post by:
Are meta tags case sensitive or does case sensitivity vary depending on the search engine a user is using? I've read that some search engines care about case wrt meta tags (for keywords in...
3
by: Barbara White | last post by:
Are meta tags case sensitive or does case sensitivity vary depending on the search engine a user is using? I'm wondering whether there's a standard regarding case (and other rules) in meta tags...
0
by: Joerg Erdmenger | last post by:
Hi there, I have an issue with tsearch. I'm using tsearch as a search mechanism on a website making various queries created from the words that a user has put in. So I query for all the words...
13
by: Nigel J. Andrews | last post by:
This will be a little vague, it was last night and I can't now do the test in that db (see below) so can't give the exact wording. I seem to remember a report a little while ago about tsearch v2...
0
by: Rajesh Kumar Mallah | last post by:
Hi, I think when search terms have "."s in them they become case sensitive in tsearch searches. How can we make them insensitive? Regds Mallah.
1
by: ericswebber | last post by:
Case Insensitive Search with Sensitive Replace -------------------------------------------------------------------- Need a REGEX case insensitve search & replace where case of found string is...
1
by: benhoefer | last post by:
I have been searching around and have not been able to find any info on this. I have a unique situation where I need a case sensitive map: std::map<string, intimap; I need to be able to run a...
11
by: Rafe | last post by:
Hi, I'm working within an application (making a lot of wrappers), but the application is not case sensitive. For example, Typing obj.name, obj.Name, or even object.naMe is all fine (as far as...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.