You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SELECT LIST(F, '')
FROM (
SELECT CAST(ASCII_CHAR(0XFF) AS BLOB SUB_TYPE 0) AS F
FROM RDB$DATABASE
UNION ALL
SELECT CAST(ASCII_CHAR(0XDE) AS BLOB SUB_TYPE 0) AS F
FROM RDB$DATABASE
)
returns 0x2E2E instead of the expected 0xFFDE. Internally the contents is treated as text and thus gets corrected by the blob filter (non-ASCII characters are replaced with dots).
The plain concatenation works correctly though:
SELECT CAST(ASCII_CHAR(0XFF) AS BLOB SUB_TYPE 0) || CAST(ASCII_CHAR(0XDE) AS BLOB SUB_TYPE 0)
FROM RDB$DATABASE
I'd say it's incorrect either. Binary data (regardless being blob or string) should not be treated as text data (and thus no transliteration must happen).
Submitted by: @dyemanov
Is related to QA566
Test case:
SELECT LIST(F, '')
FROM (
SELECT CAST(ASCII_CHAR(0XFF) AS BLOB SUB_TYPE 0) AS F
FROM RDB$DATABASE
UNION ALL
SELECT CAST(ASCII_CHAR(0XDE) AS BLOB SUB_TYPE 0) AS F
FROM RDB$DATABASE
)
returns 0x2E2E instead of the expected 0xFFDE. Internally the contents is treated as text and thus gets corrected by the blob filter (non-ASCII characters are replaced with dots).
The plain concatenation works correctly though:
SELECT CAST(ASCII_CHAR(0XFF) AS BLOB SUB_TYPE 0) || CAST(ASCII_CHAR(0XDE) AS BLOB SUB_TYPE 0)
FROM RDB$DATABASE
returns 0xFFDE.
Commits: 6987232
The text was updated successfully, but these errors were encountered: