Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Scott Robison
On Dec 3, 2014 12:57 AM, Clemens Ladisch clem...@ladisch.de wrote: James K. Lowden wrote: /* Copy N bytes of SRC to DEST. */ extern void *memcpy (void *__restrict __dest, __const void *__restrict __src, size_t __n) __THROW __nonnull ((1, 2)); IIUC the

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Scott Robison
On Dec 3, 2014 12:57 AM, Clemens Ladisch clem...@ladisch.de wrote: Do you have a standard that allows NULL? The one I quoted does not. Note: I'll have to double check my copy of the C90 standard document, but my re-reading of the C99 quote leads me to the conclusion that NULL is a valid

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Clemens Ladisch
Scott Robison wrote: On Dec 3, 2014 12:57 AM, Clemens Ladisch clem...@ladisch.de wrote: Do you have a standard that allows NULL? The one I quoted does not. Note: I'll have to double check my copy of the C90 standard document, but my re-reading of the C99 quote leads me to the conclusion that

[sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Jonathan Moules
Hi, Just a quick request/suggestion. Currently SQLITE_BUSY events return an error of Database is locked. Is it possible to change this to Database is busy or something similar? I ask because when someone then goes googling for SQLite database locked, they'll end up thinking they're hitting the

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread RSmith
On 2014/12/03 13:00, Jonathan Moules wrote: Hi, Just a quick request/suggestion. Currently SQLITE_BUSY events return an error of Database is locked. Is it possible to change this to Database is busy or something similar? I ask because when someone then goes googling for SQLite database

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Stephen Chrzanowski
Although I think there is already an error result, one situation might be when the DB is in a read only state. On Wed, Dec 3, 2014 at 6:15 AM, RSmith rsm...@rsweb.co.za wrote: On 2014/12/03 13:00, Jonathan Moules wrote: Hi, Just a quick request/suggestion. Currently SQLITE_BUSY events

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Simon Slavin
On 3 Dec 2014, at 2:20pm, Stephen Chrzanowski pontia...@gmail.com wrote: Although I think there is already an error result, one situation might be when the DB is in a read only state. I just thought of the database /file/ being marked 'read-only'. But it turns out that there's a different

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Stephen Chrzanowski
To me, a BUSY state would mean that everything up to actually reading or writing the data out is valid, but, the response time coming back was just too long, so a timeout hit which might mean that a retry later might be appropriate. To me, a timeout = busy, but, locked != busy. When something is

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Hick Gunter
I think the error messages are distinct enough as is. SQLITE_BUSY means that some connection is BUSY with a write transaction and has locked the database file; presumably, it will be possible to write to the database when the current writer has finished, just not now or within the specified

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Simon Slavin
On 3 Dec 2014, at 3:10pm, Hick Gunter h...@scigames.at wrote: SQLITE_BUSY means that some connection is BUSY with a write transaction and has locked the database file; presumably, it will be possible to write to the database when the current writer has finished, just not now or within the

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Richard Hipp
On Wed, Dec 3, 2014 at 10:18 AM, Simon Slavin slav...@bigfraud.org wrote: On 3 Dec 2014, at 3:10pm, Hick Gunter h...@scigames.at wrote: SQLITE_BUSY means that some connection is BUSY with a write transaction and has locked the database file; presumably, it will be possible to write to the

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Keith Medcalf
From https://www.sqlite.org/rescode.html#busy In both cases there are specific extended codes that may further pinpoint the source just in case you do not know what you are doing at the time the result code was returned. Interpretation is only difficult if you do not know what you are doing

Re: [sqlite] database is locked for SQLITE_BUSY

2014-12-03 Thread Simon Slavin
On 3 Dec 2014, at 3:20pm, Richard Hipp d...@sqlite.org wrote: https://www.sqlite.org/rescode.html#busy Thanks, Richard. I have somehow never seen that. I had no idea that the difference between _BUSY and _LOCKED was purely about whether the conflicting access was from the same connection.

[sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Jonathan Leslie
I'm on a window 7 x64 machine, at a cmd.exe prompt.   This is what I tried:  C:\jonesqlite3 test2.db3SQLite version 3.8.5 2014-06-04 14:06:34Enter .help for usage hints.sqlite CREATE TABLE Files (name TEXT PRIMARY KEY,contents BLOB);sqlite INSERT INTO Files (name,contents) VALUES

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Scott Robison
On Wed, Dec 3, 2014 at 2:17 AM, Clemens Ladisch clem...@ladisch.de wrote: Scott Robison wrote: On Dec 3, 2014 12:57 AM, Clemens Ladisch clem...@ladisch.de wrote: Do you have a standard that allows NULL? The one I quoted does not. Note: I'll have to double check my copy of the C90

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Stephan Beal
On Wed, Dec 3, 2014 at 5:35 PM, Scott Robison sc...@casaderobison.com wrote: standards have all been ISO standards. Pedantic? Yes. Obviously DRH is willing to make the code more portable as long as it doesn't violate ANSI-C, hence his patch early in the thread (see

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Scott Robison
On Wed, Dec 3, 2014 at 9:50 AM, Stephan Beal sgb...@googlemail.com wrote: On Wed, Dec 3, 2014 at 5:35 PM, Scott Robison sc...@casaderobison.com wrote: standards have all been ISO standards. Pedantic? Yes. Obviously DRH is willing to make the code more portable as long as it doesn't violate

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Clemens Ladisch
Jonathan Leslie wrote: I'm at a cmd.exe prompt. sqlite INSERT INTO Files (name,contents) VALUES ('tsql.lis',X$(od -A n -t x1 tsql.lis|tr -d '\r\n\t ')); Error: near $(od -A n -t x1 tsql.lis|tr -d '\r\n\t '): syntax error I'm trying to store the file tsql.lis as a blob, and od.exe and

[sqlite] Using authorizer callback together with user authentication module in SQLite version 3.8.7

2014-12-03 Thread Ulrich Telle
I'd like to use the authorizer callback together with the new user authentication module introduced in SQLite version 3.8.7. However, I experience problems in compiling my application using a SQLite library compiled with SQLITE_USER_AUTHENTICATION defined. sqlite3.h defines the

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread James K. Lowden
On Wed, 03 Dec 2014 08:56:44 +0100 Clemens Ladisch clem...@ladisch.de wrote: James K. Lowden wrote: /* Copy N bytes of SRC to DEST. */ extern void *memcpy (void *__restrict __dest, __const void *__restrict __src, size_t __n) __THROW __nonnull ((1, 2)); IIUC

Re: [sqlite] Bug report: USBAN failure

2014-12-03 Thread Scott Robison
On Wed, Dec 3, 2014 at 5:46 PM, Simon Slavin slav...@bigfraud.org wrote: On 4 Dec 2014, at 12:26am, James K. Lowden jklow...@schemamania.org wrote: What to do is another question. SQLite can surely ignore it. If I felt strongly about it, I'd submit a bug report to GCC because IIUC the

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Jonathan Leslie
From: Clemens Ladisch clem...@ladisch.de To: sqlite-users@sqlite.org Sent: Wednesday, December 3, 2014 1:00 PM Subject: Re: [sqlite] trying to store a file as a blob. caught on syntax... Jonathan Leslie wrote: I'm at a cmd.exe prompt. sqlite INSERT

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Keith Medcalf
select writefile(name, contents) from files where name='filename.ext'; --- Theory is when you know everything but nothing works. Practice is when everything works but no one knows why. Sometimes theory and practice are combined: nothing works and no one knows why. -Original

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Jonathan Leslie
no such function writefile. do I have to update my sqlite3 C:\jon\svn\SCEPTRE\trunk\SCEPTRE\Scenario Management\ahk_sceptresqlite3 test2.db3 SQLite version 3.8.5 2014-06-04 14:06:34 Enter .help for usage hints. sqlite select writefile(name,contents) from files where

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Jonathan Leslie
sqlite .version SQLite 3.8.5 2014-06-04 14:06:34 b1ed4f2a34ba66c29b130f8d13e9092758019212 sqlite - Original Message - From: Jonathan Leslie j...@jonathanleslie.com To: General Discussion of SQLite Database sqlite-users@sqlite.org Cc: Sent: Wednesday, December 3, 2014 8:36 PM

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Richard Hipp
On Wed, Dec 3, 2014 at 8:36 PM, Jonathan Leslie j...@jonathanleslie.com wrote: no such function writefile. do I have to update my sqlite3 The writefile() function is built into recent sqlite3.exe command-line shells. Very recent once, at least. If you are not using a recent

Re: [sqlite] trying to store a file as a blob. caught on syntax...

2014-12-03 Thread Jonathan Leslie
ahperfect I'm done. Thank you all for all your help. the latest build of sqlite3 has the readfile and writefile functions in it, and they seem to be working just fine. here is the cmd.exe session showing what I did. I was then able to open the image 'i3.png' and it is exactly the

[sqlite] Search for text in all tables

2014-12-03 Thread Baruch Burstein
Hi, Is it possible to somehow search for/replace a string in all columns of all tables? Thanks -- ˙uʍop-ǝpısdn sı ɹoʇıuoɯ ɹnoʎ 'sıɥʇ pɐǝɹ uɐɔ noʎ ɟı ___ sqlite-users mailing list sqlite-users@sqlite.org