I have following sqlite query for finding words which contain character 'w'
我有以下sqlite查询,查找包含字符'w'的单词
SELECT * FROM suppliers WHERE supplier_name like '%w%';
which works fine for words like: awesome,overflow etc
这对诸如:awesome,overflow等词管用吗?
But My Database contains word like: αγαπάω , αγαπώ etc
但是我的数据库包含词:αγαπάω,αγαπώ等等
I want these words also get selected when i fired that query but some how its not working i think these are accents words but anyhow i want to solve it so will u please help me to get over that issue
我想让这些词也被选中当我启动这个查询时,但是一些如何不工作我认为这些是重音词但是不管怎样我想要解决它所以你能帮我解决这个问题。
2 个解决方案
#1
1
the letter "ω" is a greek alphabet letter, named omega, which has no connection at all with the letter "w", only the shape.
这封信“ω”是一个希腊字母字母,名叫ω,没有连接以字母“w”,只有形状。
#2
1
Please see the below example.
请看下面的例子。
;WITH CTE AS
(
SELECT StringValue = N'Record1 Data: a' UNION
SELECT StringValue = N'Record2 Data: b' UNION
SELECT StringValue = N'Record3 Data: ω' UNION -- (omega character)
SELECT StringValue = N'Record4 Data: w'
)
SELECT *
FROM CTE
WHERE StringValue LIKE N'%[wω]%'
Record 3 and 4 will be returned.
记录3和4将被返回。
Remember to add the N character before the single quote.
记住在单引号之前添加N字符。
#1
1
the letter "ω" is a greek alphabet letter, named omega, which has no connection at all with the letter "w", only the shape.
这封信“ω”是一个希腊字母字母,名叫ω,没有连接以字母“w”,只有形状。
#2
1
Please see the below example.
请看下面的例子。
;WITH CTE AS
(
SELECT StringValue = N'Record1 Data: a' UNION
SELECT StringValue = N'Record2 Data: b' UNION
SELECT StringValue = N'Record3 Data: ω' UNION -- (omega character)
SELECT StringValue = N'Record4 Data: w'
)
SELECT *
FROM CTE
WHERE StringValue LIKE N'%[wω]%'
Record 3 and 4 will be returned.
记录3和4将被返回。
Remember to add the N character before the single quote.
记住在单引号之前添加N字符。