Merge 'make comparison case sensitive' from Pavan Nambi

closes https://github.com/tursodatabase/turso/issues/3672

Reviewed-by: Pere Diaz Bou <pere-altea@homail.com>

Closes #3686
This commit is contained in:
Pere Diaz Bou
2025-10-14 20:20:02 +02:00
committed by GitHub
2 changed files with 6 additions and 1 deletions

View File

@@ -312,7 +312,7 @@ pub fn module_args_from_sql(sql: &str) -> Result<Vec<turso_ext::Value>> {
pub fn check_literal_equivalency(lhs: &Literal, rhs: &Literal) -> bool {
match (lhs, rhs) {
(Literal::Numeric(n1), Literal::Numeric(n2)) => cmp_numeric_strings(n1, n2),
(Literal::String(s1), Literal::String(s2)) => check_ident_equivalency(s1, s2),
(Literal::String(s1), Literal::String(s2)) => s1 == s2,
(Literal::Blob(b1), Literal::Blob(b2)) => b1 == b2,
(Literal::Keyword(k1), Literal::Keyword(k2)) => check_ident_equivalency(k1, k2),
(Literal::Null, Literal::Null) => true,

View File

@@ -999,3 +999,8 @@ do_execsql_test_in_memory_any_error limit-column-reference-error {
CREATE TABLE t(a);
SELECT * FROM t LIMIT (t.a);
}
do_execsql_test select-binary-collation {
SELECT 'a' = 'A';
SELECT 'a' = 'a';
} {0 1}