LIKE operator issue in Ignite Database

classic Classic list List threaded Threaded
2 messages Options
Shravya Nethula Shravya Nethula
Reply | Threaded
Open this post in threaded view
|

LIKE operator issue in Ignite Database

Hi,

We are trying to execute the following select queries with LIKE operator:

SELECT * FROM u24_166004_ltb
where customer_id like ('%059')
ORDER BY id asc OFFSET 0 ROWS FETCH NEXT 1012 ROWS ONLY
There are records in the table where customer_id endsWith ('059') but still
the query returns empty set.

SELECT * FROM u24_166004_ltb
where customer_id like ('%9')
ORDER BY id asc OFFSET 0 ROWS FETCH NEXT 1012 ROWS ONLY
This query returns correct results.

The LIKE operator is not working as expected everytime. Why is it so? Is
LIKE operator fully supported in Ignite? Is there any equivalent for LIKE
operator in Ignite?
Please go through the enclosed attachments for more details.

Regards,
Shravya Nethula. LIKE_with_(%059).jpeg
<http://apache-ignite-users.70518.x6.nabble.com/file/t1559/LIKE_with_%28%25059%29.jpeg>  
LIKE_with_(%9).jpeg
<http://apache-ignite-users.70518.x6.nabble.com/file/t1559/LIKE_with_%28%259%29.jpeg>  



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/
ezhuravlev ezhuravlev
Reply | Threaded
Open this post in threaded view
|

Re: LIKE operator issue in Ignite Database

Hi,

Do you have a small reproducer for this? I've tried to create a simple one(see attached), but it works for me.

Evgenii

чт, 22 нояб. 2018 г. в 12:18, Shravya Nethula <[hidden email]>:
Hi,

We are trying to execute the following select queries with LIKE operator:

SELECT * FROM u24_166004_ltb
where customer_id like ('%059')
ORDER BY id asc OFFSET 0 ROWS FETCH NEXT 1012 ROWS ONLY
There are records in the table where customer_id endsWith ('059') but still
the query returns empty set.

SELECT * FROM u24_166004_ltb
where customer_id like ('%9')
ORDER BY id asc OFFSET 0 ROWS FETCH NEXT 1012 ROWS ONLY
This query returns correct results.

The LIKE operator is not working as expected everytime. Why is it so? Is
LIKE operator fully supported in Ignite? Is there any equivalent for LIKE
operator in Ignite?
Please go through the enclosed attachments for more details.

Regards,
Shravya Nethula. LIKE_with_(%059).jpeg
<http://apache-ignite-users.70518.x6.nabble.com/file/t1559/LIKE_with_%28%25059%29.jpeg
LIKE_with_(%9).jpeg
<http://apache-ignite-users.70518.x6.nabble.com/file/t1559/LIKE_with_%28%259%29.jpeg



--
Sent from: http://apache-ignite-users.70518.x6.nabble.com/

SqlLikeTest.java (4K) Download Attachment