Re: [sqlite] sqlite command line tool fails to dump data

2018-01-22 Thread Simon Slavin
On 22 Jan 2018, at 4:46pm, J Decker wrote: > create table [with\0nul] ( `col\0``umn` ) Could you not ? In fact, could everybody not ? [Goes to look for ice bag or strong alcohol, whichever appears first.] Simon. ___ sqlite-users

Re: [sqlite] sqlite command line tool fails to dump data

2018-01-22 Thread J Decker
On Sun, Jan 21, 2018 at 11:48 PM, Clemens Ladisch wrote: > J Decker wrote: > >> *If any NUL characters occur at byte| offsets less than the value of the > >> fourth parameter then the resulting| string value will contain embedded > >> NULs.* > > > > So it's best used as data,

Re: [sqlite] sqlite command line tool fails to dump data

2018-01-21 Thread Clemens Ladisch
J Decker wrote: >> *If any NUL characters occur at byte| offsets less than the value of the >> fourth parameter then the resulting| string value will contain embedded >> NULs.* > > So it's best used as data, and not keys > and I see unless custom aggregate()s or function()s ... If you want

Re: [sqlite] sqlite command line tool fails to dump data

2018-01-21 Thread J Decker
On Sun, Jan 21, 2018 at 7:42 AM, Clemens Ladisch wrote: > J Decker wrote: > > insert into test (a,b) values ( ?,? ) > > bind 'hello\0world.' 'te\0st' > > says: > | If a non-negative fourth parameter is provided to

Re: [sqlite] sqlite command line tool fails to dump data

2018-01-21 Thread Clemens Ladisch
J Decker wrote: > insert into test (a,b) values ( ?,? ) > bind 'hello\0world.' 'te\0st' says: | If a non-negative fourth parameter is provided to sqlite3_bind_text() | or sqlite3_bind_text16() or sqlite3_bind_text64() then that parameter | must be

Re: [sqlite] sqlite command line tool fails to dump data

2018-01-21 Thread Luuk
On 21-01-18 16:16, J Decker wrote: > create table test (a,b) > insert into test (a,b) values ( ?,? ) > bind 'hello\0world.' 'te\0st' luuk@opensuse:~/tmp> sqlite3 SQLite version 3.8.10.2 2015-05-20 18:17:19 Enter ".help" for usage hints. Connected to a transient in-memory database. Use ".open

[sqlite] sqlite command line tool fails to dump data

2018-01-21 Thread J Decker
sqlite test.db create table test (a,b) insert into test (a,b) values ( ?,? ) bind 'hello\0world.' 'te\0st' .dump table -- output CREATE TABLE test (a,b); INSERT INTO test VALUES('hello','te'); ___ sqlite-users mailing list