Dan Book <grinnz@gmail.com> writes: > On Mon, Aug 2, 2021 at 4:28 PM Harald Jörg <haj@posteo.de> wrote: > > > Dan Book <grinnz@gmail.com> writes: > > > > > DBD::MariaDB, DBD::SQLite, and DBD::Pg are used with the unicode > > > option in any modern programs. Thus they expect decoded strings. > > > > As far as DBD::SQLite is concerned, this is only half-true. In the > > current version 1.70 there have been changes how to declare unicode > > handling, but even with DBD_SQLITE_STRING_MODE_UNICODE_STRICT you can > > feed it UTF-8 encoded byte sequences and it "just works" (but maybe > > shouldn't). > > [...] > I don't think this is correct. Mojo::SQLite has many tests to ensure > in unicode-mode that it treats strings consistently. Thanks for clarifying! I compared your code to my failing tests (as attached to https://github.com/DBD-SQLite/DBD-SQLite/issues/83) and found that I fell victim to a typo in the DBD::SQLite docs: $dbh->{string_mode} = DBD_SQLITE_STRING_MODE_UNICODE_FALLBACK; That key should read $dbh->{sqlite_string_mode). So, in effect, I ran the test with the old (broken) default encoding which is known to fail. -- Thanks again, hajThread Previous | Thread Next