Re: [sqlite] Help with confirming a couple of error traces

2017-02-01 Thread Shaobo He
Thanks, Richard. I think that I fully understand what happens now. Thanks again for your patience. May I ask that do you see null pointer deferences during development regularly? Shaobo Richard Hipp 于2017年2月1日周三 下午6:52写道: > On 2/1/17, Shaobo He wrote: >

Re: [sqlite] "DISTINCT" makes a query take 37 times as long

2017-02-01 Thread Kevin O'Gorman
On Wed, Feb 1, 2017 at 6:35 PM, Richard Hipp wrote: > On 2/1/17, Kevin O'Gorman wrote: > > I have a database of positions and moves in a strategic game, and I'm > > searching for unsolved positions that have been connected to an immediate > > ancestor.

Re: [sqlite] "DISTINCT" makes a query take 37 times as long

2017-02-01 Thread Richard Hipp
On 2/1/17, Kevin O'Gorman wrote: > I have a database of positions and moves in a strategic game, and I'm > searching for unsolved positions that have been connected to an immediate > ancestor. I'm using Python 3.5.2, and the code looks like Please provide us with the

[sqlite] "DISTINCT" makes a query take 37 times as long

2017-02-01 Thread Kevin O'Gorman
I have a database of positions and moves in a strategic game, and I'm searching for unsolved positions that have been connected to an immediate ancestor. I'm using Python 3.5.2, and the code looks like #!/usr/bin/env python3 """Output positions that are reachable but unsolved at census 18 or

Re: [sqlite] Help with confirming a couple of error traces

2017-02-01 Thread Richard Hipp
On 2/1/17, Shaobo He wrote: > Thanks for your reply. I repeated the experiment by setting > db->mallocFailed upon return. You are right that there is no segmentation > fault (there were some assertion failures: e.g, "sqlite3OomClear: Assertion > `db->lookaside.bDisable>0'

Re: [sqlite] Help with confirming a couple of error traces

2017-02-01 Thread Shaobo He
Thanks for your reply. I repeated the experiment by setting db->mallocFailed upon return. You are right that there is no segmentation fault (there were some assertion failures: e.g, "sqlite3OomClear: Assertion `db->lookaside.bDisable>0' failed"). Instead I got error messages saying out of memory.

Re: [sqlite] Help with confirming a couple of error traces

2017-02-01 Thread Richard Hipp
On 2/1/17, Shaobo He wrote: > > Basically, the error trace indicate that `sqlite3SrcListAppend` can return > a null pointer under the presence of OOM and this return value can > propagate to somewhere in the program, resulting in a null pointer > deference. An OOM

Re: [sqlite] Simple web query tool

2017-02-01 Thread Warren Young
On Feb 1, 2017, at 11:45 AM, Brian Curley wrote: > > internal file shares are all that's needed to > connect to a distributed file. …as long as your networked file system does locking properly: https://www.sqlite.org/lockingv3.html#how_to_corrupt

Re: [sqlite] Help with confirming a couple of error traces

2017-02-01 Thread Shaobo He
Hi Richard, all, It's so nice of you to help out. Now we understand better what we should do to reduce the number of false positives. Thanks a lot. I'm sorry to bother you again. But it would be great if you could provide some feedback on the new error trace returned by our tool. Basically, the

Re: [sqlite] Sqlite with Docker and mounted volumes

2017-02-01 Thread Keith Medcalf
If it is a remote filesystem (vs a local filesystem) then you must also have only one connection (ever) to the database file at any given time. Otherwise you may have issues. (Note "Single User" does not mean "Single Connection") > Hi Simon. Thank you for your answer. It's single user and

Re: [sqlite] Sqlite with Docker and mounted volumes

2017-02-01 Thread Keith Medcalf
If it is a local filesystem mounting a remote block device no problem. If it is a remote filesystem, then caveats apply (most remote/network filesystems are very broken when it comes to locking sematics) > -Original Message- > From: sqlite-users

Re: [sqlite] SQLite - SELECT query slowing down while fetching from higher offset.

2017-02-01 Thread Keith Medcalf
> When I have 1 records in the table, it takes 20 ms to fetch 10 items > from offset 0, and it increases to 220 ms to fetch 10 items from offset > 9900. > While I have 2 records in the table, it takes 20 ms to fetch 10 items > from offset 0, 440 ms for 10 items from offset 9600 and 720

Re: [sqlite] BUG: Illegal initialization in icu.c : sqlite3IcuInit

2017-02-01 Thread Scott Robison
On Wed, Feb 1, 2017 at 3:48 PM, Keith Medcalf wrote: > > > On Tue, 31 Jan 2017 15:50:08 -0800 James K. Lowden < > jklow...@schemamania.org> wrote: > > > Last year there was much rejoicing when Microsoft decided to bundle > > SQLite with Windows. That leaves me with a new

Re: [sqlite] BUG: Illegal initialization in icu.c : sqlite3IcuInit

2017-02-01 Thread Keith Medcalf
> On Tue, 31 Jan 2017 15:50:08 -0800 James K. Lowden > wrote: > Last year there was much rejoicing when Microsoft decided to bundle > SQLite with Windows. That leaves me with a new question: if SQLite > announced its intention to move to C11 in 2018, would that

Re: [sqlite] JPA

2017-02-01 Thread Simon Slavin
On 1 Feb 2017, at 10:01pm, Cecil Westerhof wrote: > 2017-02-01 19:25 GMT+01:00 Jens Alfke : > >> Can SQLite be used with JPA? >> >> Sure, I’ve been SQLite for years ;-) > > ​Using SQLite does not mean that you use it with JPA. I use it with Python

Re: [sqlite] sqlite3_errmsg() after sqlitr3_exec() on ATTACHed DB

2017-02-01 Thread Ward WIllats
> On Feb 1, 2017, at 1:18 PM, Igor Tandetnik wrote: > > On 2/1/2017 10:32 AM, Ward WIllats wrote: >> When I perform an sqlite3_exec() to DELETE too many rows in the secondary >> ATTACHed database and a disk or database full error occurs, I properly get a >> code 13

Re: [sqlite] JPA

2017-02-01 Thread Cecil Westerhof
2017-02-01 19:25 GMT+01:00 Jens Alfke : > > > Can SQLite be used with JPA? > > Sure, I’ve been SQLite for years ;-) > ​Using SQLite does not mean that you use it with JPA. I use it with Python and Bash and also with JDBC. None of those is JPA. ;-) How do you use the combo

Re: [sqlite] sqlite3_errmsg() after sqlitr3_exec() on ATTACHed DB

2017-02-01 Thread Igor Tandetnik
On 2/1/2017 10:32 AM, Ward WIllats wrote: When I perform an sqlite3_exec() to DELETE too many rows in the secondary ATTACHed database and a disk or database full error occurs, I properly get a code 13 returned from the API. But if I then turn around and call sqlite3_errmsg() I get "not an

Re: [sqlite] Sqlite with Docker and mounted volumes

2017-02-01 Thread Sebastián Guevara
Hi Simon. Thank you for your answer. It's single user and without concurrency. On Feb 1, 2017 18:32, "Simon Slavin" wrote: On 1 Feb 2017, at 5:08pm, Sebastián Guevara wrote: > Hello to all. We are contemplating using SQLite from within a

Re: [sqlite] Help with custom collation

2017-02-01 Thread x
Thanks Clemens. You’re right about changing the UTF8String* to char* as it now works but when trying it with a column containing Unicode characters it didn’t. I’d have liked to have tried it with windows wchar_t* type but If I try using if (sqlite3_create_collation16(SQLiteDB,

Re: [sqlite] Simple web query tool

2017-02-01 Thread Brian Curley
Would the SQLite Manager extension on Firefox suffice? I don't know the scope of your use case, but internal file shares are all that's needed to connect to a distributed file. You can achieve variables through a miscellaneous table and coalesce() as needed. Regards. On Wed, Feb 1, 2017 at

Re: [sqlite] Does SQLite use field definitions?

2017-02-01 Thread Donald Griggs
The default maximum string length is one billion (10 ** 9). You can configure the maximum up to about twice that. https://www.sqlite.org/limits.html If column affinity matters in your application, you may want to declare your column as TEXT or maybe CLOB (identical effect.)

Re: [sqlite] JPA

2017-02-01 Thread Jens Alfke
> On Feb 1, 2017, at 6:19 AM, Cecil Westerhof wrote: > > Can SQLite be used with JPA? Sure, I’ve been SQLite for years ;-) —Jens Peter Alfke ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org

Re: [sqlite] Does SQLite use field definitions?

2017-02-01 Thread Jens Alfke
> On Feb 1, 2017, at 7:41 AM, Clyde Eisenbeis wrote: > > However, I don't see any complaints by SQLite when I use MEMO. SQLite actually ignores the column data types completely in a table spec. You can store any type of data in any column of any table. (In other words,

Re: [sqlite] SQLite - SELECT query slowing down while fetching from higher offset.

2017-02-01 Thread Jens Alfke
> On Feb 1, 2017, at 7:18 AM, Richard Hipp wrote: > > See also https://www.sqlite.org/rowvalue.html#scrolling_window_queries > This approach comes with a major caveat that’s not mentioned in the text: the data

Re: [sqlite] Simple web query tool

2017-02-01 Thread Doug Currie
On Wed, Feb 1, 2017 at 11:10 AM, Jay Kreibich wrote: > I'm looking for an *extremely* simple web tool that will allow me to > configure a dozen or so stored queries, which people can then select and > run on an internal server. While I wouldn't call it extremely simple, the

Re: [sqlite] Sqlite with Docker and mounted volumes

2017-02-01 Thread Simon Slavin
On 1 Feb 2017, at 5:08pm, Sebastián Guevara wrote: > Hello to all. We are contemplating using SQLite from within a Docker > container accessing a DB on a mounted volume. Does your setup involve two or more users accessing the data at the same time ? It’s possible

Re: [sqlite] Help with custom collation

2017-02-01 Thread Clemens Ladisch
x wrote: > int Compare(void* Data, int Len1, const void *s1, int Len2, const void *s2) > { > const UTF8String *S1 = static_cast(s1), > *S2 = static_cast(s2); > return 0; > } > > if (sqlite3_create_collation(SQLiteDB, "Compare", SQLITE_UTF8, NULL, > ) != SQLITE_OK)

Re: [sqlite] Simple web query tool

2017-02-01 Thread Simon Slavin
On 1 Feb 2017, at 4:10pm, Jay Kreibich wrote: > I'm looking for an *extremely* simple web tool that will allow me to > configure a dozen or so stored queries, which people can then select and > run on an internal server. If the system supports a query variable or two, > that

[sqlite] Sqlite with Docker and mounted volumes

2017-02-01 Thread Sebastián Guevara
Hello to all. We are contemplating using SQLite from within a Docker container accessing a DB on a mounted volume. I don't expect any performance issues if the mounted volume is a directory from the host machine. But what if it's a shared storage, something like Flocker (

[sqlite] Help with custom collation

2017-02-01 Thread x
The collation function used was as follows int Compare(void* Data, int Len1, const void *s1, int Len2, const void *s2) { const UTF8String *S1 = static_cast(s1), *S2 = static_cast(s2); return 0; } Which was registered with the following code if

[sqlite] Simple web query tool

2017-02-01 Thread Jay Kreibich
I'm looking for an *extremely* simple web tool that will allow me to configure a dozen or so stored queries, which people can then select and run on an internal server. If the system supports a query variable or two, that would be fantastic, but I don't even need that. Any thoughts? Or do I

Re: [sqlite] JPA

2017-02-01 Thread Cecil Westerhof
2017-02-01 15:41 GMT+01:00 Simon Slavin : > > > ​It seems to be what I want. > > Excellent. > > Now, if there were just an object persistence engine for JavaScript, I’d > be happier. That’s what I was looking for when I came across OrmLite. > > Hmm. With IndexedDB it

Re: [sqlite] Does SQLite use field definitions?

2017-02-01 Thread Clyde Eisenbeis
I don't see MEMO listed. I needed to use MEMO in Microsoft Access to handle char strings longer than 256. However, I don't see any complaints by SQLite when I use MEMO. On Tue, Jan 31, 2017 at 10:33 AM, Hick Gunter wrote: > Yes. See http://sqlite.org/lang_createtable.html for

[sqlite] sqlite3_errmsg() after sqlitr3_exec() on ATTACHed DB

2017-02-01 Thread Ward WIllats
Hello. In our embedded system we have two databases ATTACHed to each other and size constrained with max_page pragmas directed at each. (Different filesystems: one is on a tmpfs in RAM, the other on JFFS). When I perform an sqlite3_exec() to DELETE too many rows in the secondary ATTACHed

Re: [sqlite] SQLite - SELECT query slowing down while fetching from higher offset.

2017-02-01 Thread Richard Hipp
On 2/1/17, Igor Tandetnik wrote: > On 2/1/2017 9:50 AM, Anthrathodiyil, Sabeel (S.) wrote: >> I am facing issue with SQLite performance when having more records in the >> table and fetching from higher offsets > > https://www.sqlite.org/cvstrac/wiki?p=ScrollingCursor See also

Re: [sqlite] SQLite - SELECT query slowing down while fetching from higher offset.

2017-02-01 Thread Igor Tandetnik
On 2/1/2017 9:50 AM, Anthrathodiyil, Sabeel (S.) wrote: I am facing issue with SQLite performance when having more records in the table and fetching from higher offsets https://www.sqlite.org/cvstrac/wiki?p=ScrollingCursor Performance of a query with OFFSET N is roughly equivalent to that

Re: [sqlite] SQLite - SELECT query slowing down while fetching from higher offset.

2017-02-01 Thread Simon Slavin
On 1 Feb 2017, at 2:50pm, Anthrathodiyil, Sabeel (S.) wrote: > When I have 1 records in the table, it takes 20 ms to fetch 10 items > from offset 0, and it increases to 220 ms to fetch 10 items from offset 9900. > While I have 2 records in the table, it takes 20

Re: [sqlite] DELETE when DB is full

2017-02-01 Thread Ward WIllats
> On Jan 31, 2017, at 3:54 PM, Simon Slavin wrote: > > On 31 Jan 2017, at 10:40pm, Warren Young wrote: > >> On Jan 31, 2017, at 2:03 PM, Ward WIllats wrote: >> >>> the delete sometimes (very rarely) fails with a 13 "disk or

[sqlite] SQLite - SELECT query slowing down while fetching from higher offset.

2017-02-01 Thread Anthrathodiyil, Sabeel (S.)
Hi, I am facing issue with SQLite performance when having more records in the table and fetching from higher offsets, though I have proper index in place. Using SQLite version 3.7.10 running on ARM Cortex A5 processor. Here is my schema (relevant table and index) and query CREATE TABLE

Re: [sqlite] JPA

2017-02-01 Thread Simon Slavin
On 1 Feb 2017, at 2:33pm, Cecil Westerhof wrote: > ​It seems to be what I want. Excellent. Now, if there were just an object persistence engine for JavaScript, I’d be happier. That’s what I was looking for when I came across OrmLite. Hmm. With IndexedDB it should

Re: [sqlite] JPA

2017-02-01 Thread Cecil Westerhof
2017-02-01 15:29 GMT+01:00 Cecil Westerhof : > That is a fast reply. :-D > > 2017-02-01 15:23 GMT+01:00 Simon Slavin : > >> >> > Can SQLite be used with JPA? >> >> I think you’re talking about persistent Java objects. You might want to >> look at

Re: [sqlite] JPA

2017-02-01 Thread Cecil Westerhof
That is a fast reply. :-D 2017-02-01 15:23 GMT+01:00 Simon Slavin : > > > Can SQLite be used with JPA? > > I think you’re talking about persistent Java objects. You might want to > look at this: > > > > SQLite is one of the database engines it

Re: [sqlite] JPA

2017-02-01 Thread Simon Slavin
On 1 Feb 2017, at 2:19pm, Cecil Westerhof wrote: > Can SQLite be used with JPA? I think you’re talking about persistent Java objects. You might want to look at this: SQLite is one of the database engines it supports. Sorry but I’m not a Java

[sqlite] JPA

2017-02-01 Thread Cecil Westerhof
Can SQLite be used with JPA? -- Cecil Westerhof ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

[sqlite] Information about Windows Iot Sql Lite

2017-02-01 Thread Magni, Andrea - IT CONSULTANT
Good Afternoon, following this example [ http://blog.chrisbriggsy.com/Using-SQLITE-in-Windows-10-IoT-Core-Insider-Preview/ ]( http://blog.chrisbriggsy.com/Using-SQLITE-in-Windows-10-IoT-Core-Insider-Preview/ ) Im trying to use Sql and Linq with c# and windows iot. I'm not able to