I would suggest that if you ran:

SELECT ROWID,MSG,typeof(MSG) FROM LOG;

and read https://sqlite.org/datatype3.html

you would have a better idea of what is going on. You might still consider
it a but, but it is expected behavior.

Gerry

On Fri, Dec 13, 2019 at 8:51 AM Sascha Ziemann <cev...@gmail.com> wrote:

> I have a problem to find rows in a database when I write in hex notation:
>
> CREATE TABLE LOG (MSG VARCHAR(6291456) NOT NULL);
> INSERT INTO LOG VALUES
>
> (X'666163696c6974793d6461656d6f6e3b636f6d706f6e656e743d6e616d65643b746578743d7368757474696e6720646f776e');
> INSERT INTO LOG VALUES ('facility=daemon;component=named;text=shutting
> down');
> SELECT ROWID,MSG FROM LOG;                                         --
> returns both rows
> SELECT ROWID,MSG FROM LOG WHERE MSG LIKE '%down';                  --
> returns just the second
> SELECT ROWID,MSG FROM LOG WHERE CAST(MSG AS VARCHAR) LIKE '%down'; --
> returns both rows
>
> This looks like a bug to me.
>
> Regards
> _______________________________________________
> sqlite-users mailing list
> sqlite-users@mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to