Re: [sqlite] fallocate on ZFS

2014-04-28 Thread Steve Wills
Hi, On Wed, Apr 23, 2014 at 03:52:03PM -0400, Richard Hipp wrote: > On Wed, Apr 23, 2014 at 3:46 PM, Steve Wills wrote: > > > On Wed, Apr 23, 2014 at 03:39:21PM -0400, Richard Hipp wrote: > > > > > > So what problem are you seeing, exactly? Is the fact that > > >

Re: [sqlite] When to open/close connections

2014-04-28 Thread Yuriy Kaminskiy
Simon Slavin wrote: > On 28 Apr 2014, at 11:11pm, RSmith wrote: > >> Second approach is better when you rarely access the database, also it will >> make sure releases happen (or at least provide immediate errors if not), but >> keeping a connection open is much better when

Re: [sqlite] When to open/close connections

2014-04-28 Thread Simon Slavin
On 28 Apr 2014, at 11:11pm, RSmith wrote: > Second approach is better when you rarely access the database, also it will > make sure releases happen (or at least provide immediate errors if not), but > keeping a connection open is much better when hundreds of accesses

Re: [sqlite] When to open/close connections

2014-04-28 Thread RSmith
Second approach is better when you rarely access the database, also it will make sure releases happen (or at least provide immediate errors if not), but keeping a connection open is much better when hundreds of accesses happen in terms of speed - especially loads of small queries, large queries

[sqlite] When to open/close connections

2014-04-28 Thread Peter Haworth
There's a discussion on another forum I'm on about whether it's good practice to open an SQLite database as part of program initialization and close it when the program terminates, or whether the connection should be opened and closed around each transaction. I've always used the first approach

Re: [sqlite] SELECT alias name limitation

2014-04-28 Thread RSmith
Just to be complete - the following works for me usually to achieve what you seem to need from the first posted select: Your Select: SELECT CASE WHEN SEX='M' THEN 'MALE' WHEN SEX='F' THEN 'FEMALE' ELSE 'OTHER' END AS p, NAME||' - '||p AS 'NAME' FROM DB; The CTE version: WITH Sx(ID,

Re: [sqlite] LSM bug

2014-04-28 Thread sqlite
I didn't know this list strips attachments, so the source file is here: http://derkarl.org/~charles/runlsm.cpp On Monday, April 28, 2014 01:41:02 PM sql...@charles.derkarl.org wrote: > Hi, > > I'm not exactly sure this is the right forum for my problem, as I know that > LSM is experimental,

[sqlite] LSM bug

2014-04-28 Thread sqlite
Hi, I'm not exactly sure this is the right forum for my problem, as I know that LSM is experimental, but here we go. I tried loading a whole lot of data using LSM. The majority of the data goes int a single huge transaction (begin/commit pair). My program segfaults once we're 1.61GB into my

Re: [sqlite] SELECT alias name limitation

2014-04-28 Thread Petite Abeille
On Apr 28, 2014, at 9:27 PM, Staffan Tylen wrote: > (Thinking about it maybe WITH could be used, Yes, it’s a typical use case for WITH. > but that doesn't answer the first question.) One cannot refer to an identifier in the same section it was declared in, and

Re: [sqlite] SELECT alias name limitation

2014-04-28 Thread RSmith
It's not inconsistent at all - You cannot use an Alias in the same bit of a statement that creates the alias, but can use it freely in any next section. This is the documented behaviour at least - so it has nothing to do with "sometimes", it is quite specific. So to break down your SQL: SELECT

[sqlite] SELECT alias name limitation

2014-04-28 Thread Staffan Tylen
Why is p not valid here: SELECT CASE WHEN SEX='M' THEN 'MALE' WHEN SEX='F' THEN 'FEMALE' ELSE 'OTHER' END AS p, NAME||' - '||p AS 'NAME' FROM DB; when it's valid here: SELECT CASE WHEN SEX='M' THEN 'MALE' WHEN SEX='F' THEN 'FEMALE' ELSE 'OTHER' END AS p, NAME FROM DB ORDER BY p;

[sqlite] [BUG] vfstraceAccess() logs as xDelete

2014-04-28 Thread Michael McTernan
Hi all, A very trivial bug here - in src/test_vfstrace.c, vfstraceAccess() the log message is wrong: static int vfstraceAccess( sqlite3_vfs *pVfs, const char *zPath, int flags, int *pResOut ){ vfstrace_info *pInfo = (vfstrace_info*)pVfs->pAppData; sqlite3_vfs *pRoot =

Re: [sqlite] WP8 compiled version

2014-04-28 Thread Vadim Kantorov
Or did you mean that recompilation for WP8 is not required because FTS4 is already there? Thanks, 2014-04-28 11:15 GMT+02:00 Vadim Kantorov : > Hello, > > Thank you for the quick response. > Yes, it's mono-based, and they have bindings for native SQLite libs, > so it may

Re: [sqlite] WP8 compiled version

2014-04-28 Thread Vadim Kantorov
Hello, Thank you for the quick response. Yes, it's mono-based, and they have bindings for native SQLite libs, so it may be fine. I've seen there's a native version of SQLite compiled for WP8 (which supports native code to some extent) on the Downloads page. Are the issues blocking such

[sqlite] EF6 Issue (2)

2014-04-28 Thread Matthijs ter Woord
So, after some debugging, I found a way to attach to a given database by code. See the sample project at http://www.terwoord.nl/SQLiteEF6Test.zip The project starts with retrieving a temporary file. It then saves a sample entity MyMessageObj. Next it retrieves it in a new DbContext. In a nested