Re: [sqlite] The cli truncates values containing null chars

2017-05-09 Thread Richard Hipp
On 5/9/17, Jens Alfke wrote: > > It has always annoyed me that the CLI just dumps blobs directly to stdout. Have you tried setting ".mode quote"? Perhaps add that to your ~/sqlite.rc file? -- D. Richard Hipp d...@sqlite.org ___ sqlite-users mailing l

Re: [sqlite] The cli truncates values containing null chars

2017-05-09 Thread petern
Some output modes of shell.c already automatically hex print BLOB's: static void output_hex_blob(FILE *out, const void *pBlob, int nBlob){ int i; char *zBlob = (char *)pBlob; raw_printf(out,"X'"); for(i=0; i That function is called within the output loop switch statement: case MODE_

Re: [sqlite] The cli truncates values containing null chars

2017-05-09 Thread Jens Alfke
> On May 9, 2017, at 4:21 AM, Hick Gunter wrote: > > You may store any sequence of bytes in a BLOB, but please do not expect a > data storage layer library to handle opaque objects. This sounds like a typo? I definitely _do_ expect a data storage library to handle opaque/binary objects. > If

Re: [sqlite] The cli truncates values containing null chars

2017-05-09 Thread Hick Gunter
her Chrysostomos Gesendet: Dienstag, 09. Mai 2017 05:02 An: sqlite-users@mailinglists.sqlite.org Betreff: [sqlite] The cli truncates values containing null chars While the SQLite database itself supports embedded nulls without any problems, the command-line utility truncates values at the first n

[sqlite] The cli truncates values containing null chars

2017-05-09 Thread Father Chrysostomos
While the SQLite database itself supports embedded nulls without any problems, the command-line utility truncates values at the first null character, which can be very confusing if a field begins with a null character. (I spent an hour debugging my code, trying to figure out why it was not writi