Summary: | PostgreSQL uses case-sensitive search for LIKE SQL operator, Kexi's default is case-insensitive | ||
---|---|---|---|
Product: | [Applications] KEXI | Reporter: | Roman Shtemberko <shtemberko> |
Component: | KexiDB | Assignee: | Jarosław Staniek <staniek> |
Status: | CLOSED FIXED | ||
Severity: | normal | CC: | adam, inksi, staniek |
Priority: | NOR | ||
Version: | 2.9.4 | ||
Target Milestone: | 2.9.5 | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | http://commits.kde.org/calligra/03b43ccbfd65c17362003047e7fec8ecef3c3bb7 | Version Fixed In: | 2.9.5 |
Sentry Crash Report: |
Description
Roman Shtemberko
2015-05-25 12:51:27 UTC
Changing summary to note that it's really a bug. The risk in this bug is that if user copies a query from a mysql or sqlite-based kexi project to a postgresql-based one, the results differ if LIKE is used. Applies to "NOT LIKE" operator too. Git commit 03b43ccbfd65c17362003047e7fec8ecef3c3bb7 by Jaroslaw Staniek. Committed on 31/05/2015 at 20:01. Pushed by staniek into branch 'calligra/2.9'. Consistency: use ILIKE/NOT ILIKE operator instead of LIKE for PostgreSQL This fixes the issue "PostgreSQL uses case-sensitive search for LIKE SQL operator, Kexi's default is case-insensitive" The approach isn't generic enough for other expressions (the context of connection could be better) but it's already much better than ignoring differences between servers REVIEW:123952 FIXED-IN:2.9.5 M +1 -0 kexi/kexidb/drivers/pqxx/pqxxdriver.cpp M +12 -12 kexi/plugins/queries/kexiquerydesignerguieditor.cpp M +1 -1 kexi/widget/tableview/kexicomboboxpopup.cpp M +3 -3 libs/db/connection.cpp M +1 -0 libs/db/driver.cpp M +5 -0 libs/db/driver_p.h M +32 -27 libs/db/expression.cpp M +16 -12 libs/db/expression.h M +2 -2 libs/db/parser/parser_p.cpp http://commits.kde.org/calligra/03b43ccbfd65c17362003047e7fec8ecef3c3bb7 Git commit 928b7a69672f7f9660aafeab5f5af1dd0d171ed0 by Jaroslaw Staniek. Committed on 02/07/2015 at 21:08. Pushed by staniek into branch 'master'. Allow to use driver in token-to-string conversions + fix LIKE operator for PostgreSQL Based on calligra 2.9 03b43ccbfd65c173620: Consistency: use ILIKE/NOT ILIKE operator instead of LIKE for PostgreSQL This fixes the issue "PostgreSQL uses case-sensitive search for LIKE SQL operator, Kexi's default is case-insensitive" "The approach isn't generic enough for other expressions (the context of connection could be better) but it's already much better than ignoring differences between servers" M +45 -45 autotests/ExpressionsTest.cpp M +1 -0 src/KDbDriver_p.cpp M +5 -0 src/KDbDriver_p.h M +1 -0 src/drivers/postgresql/PostgresqlDriver.cpp M +7 -5 src/expression/KDbBinaryExpression.cpp M +6 -3 src/expression/KDbConstExpression.cpp M +15 -8 src/expression/KDbExpression.cpp M +4 -2 src/expression/KDbExpression.h M +29 -19 src/expression/KDbExpressionData.h M +5 -3 src/expression/KDbFunctionExpression.cpp M +11 -5 src/expression/KDbNArgExpression.cpp M +5 -2 src/expression/KDbQueryParameterExpression.cpp M +8 -5 src/expression/KDbUnaryExpression.cpp M +5 -2 src/expression/KDbVariableExpression.cpp M +2 -2 src/parser/KDbParser_p.cpp M +18 -8 src/parser/generate_parser_code.sh M +11 -5 src/parser/generated/KDbToken.cpp M +7 -3 src/parser/generated/KDbToken.h http://commits.kde.org/kdb/928b7a69672f7f9660aafeab5f5af1dd0d171ed0 |