Re: [sqlite] Documentation bug. Detecting NULL extension arguments.

2017-06-30 Thread Richard Hipp
On 6/30/17, petern wrote: > sqlite3_value_type() definitely deserves at least one document sentence The change at https://www.sqlite.org/src/info/0db20efe201736b3 will appear in the next release. -- D. Richard Hipp d...@sqlite.org ___ sqlite-users ma

Re: [sqlite] Documentation bug. Detecting NULL extension arguments.

2017-06-30 Thread petern
Thank you for the quick reply. After reading your reply and grepping around for more examples containing sqlite3_type_value I see now the documentation gives the impression that return types only apply to sqlite3_value_numeric_type(). Had I clicked randomly on the link to https://sqlite.org/c3r

Re: [sqlite] Documentation bug. Detecting NULL extension arguments.

2017-06-30 Thread Richard Hipp
On 6/30/17, petern wrote: > Is this the recommended way for any argument type? > > zCol = (const char*)sqlite3_value_text(argv[i]); > if( 0==zCol ) return; No. What you have above detects out-of-memory errors when trying to convert an argument in some non-TEXT type in to TEXT, or when conver

[sqlite] Documentation bug. Detecting NULL extension arguments.

2017-06-30 Thread petern
Is this the recommended way for any argument type? zCol = (const char*)sqlite3_value_text(argv[i]); if( 0==zCol ) return; Docs say protected_sqlite3_value can represent NULL but how is not explained anywhere. https://www.sqlite.org/c3ref/value_blob.html https://www.sqlite.org/c3ref/value.htm

Re: [sqlite] [OT] UTF8-BOM and text encoding detection (was: UTF8-BOM not disregarded in CSV import)

2017-06-30 Thread Niall O'Reilly
On 29 Jun 2017, at 20:19, Peter da Silva wrote: The DECsystem 10 guys also referred to the other subdivisions of their 36 bit words as bytes, sometimes, they could be 6, 7, 8, or 9 bits long. I think they had special instructions for operating on them, but they weren’t directly addressable.