Re: [sqlite] System.Data.SQLite and VS2012 RTM designer support

2012-09-10 Thread Joe Mistachkin
Browser IA wrote: > > Um, I'm sorry, that is not consistent with...our experience. My teammates and I have > been running 1.0.66 with full designer support in VS 2010 for well over the past two > years, that is, as long as VS 2010 has been out! It may be the case that this is not > an "officially

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Dan Kennedy
On 09/11/2012 11:12 AM, Keith Chew wrote: Hi Jay In WAL mode that's only half incorrect. Your description of NORMAL seems correct, but FULL should be fully durable. The WAL file may need to be checkpointed on startup, but the if the commit happens in WAL/FULL, you should have

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Keith Chew
Hi Jay > > In WAL mode that's only half incorrect. Your description of NORMAL > seems correct, but FULL should be fully durable. The WAL file may > need to be checkpointed on startup, but the if the commit happens in > WAL/FULL, you should have full durability. > This is the reason for

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Jay A. Kreibich
On Mon, Sep 10, 2012 at 09:50:58PM -0500, Jay A. Kreibich scratched on the wall: > On Tue, Sep 11, 2012 at 01:58:23AM +0100, Simon Slavin scratched on the wall: > > On 11 Sep 2012, at 12:55am, Keith Chew wrote: > > > > and I know FULL (1) will provide that. The question is

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Jay A. Kreibich
On Tue, Sep 11, 2012 at 03:11:57PM +1200, Keith Chew scratched on the wall: > Hi Jay > > > http://www.sqlite.org/pragma.html#pragma_synchronous > > > > When synchronous is FULL (2), the SQLite database engine will use > > the xSync method of the VFS to ensure that all content is

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Keith Chew
Hi Jay > http://www.sqlite.org/pragma.html#pragma_synchronous > > When synchronous is FULL (2), the SQLite database engine will use > the xSync method of the VFS to ensure that all content is safely > written to the disk surface prior to continuing. This ensures > that

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Jay A. Kreibich
On Tue, Sep 11, 2012 at 01:58:23AM +0100, Simon Slavin scratched on the wall: > On 11 Sep 2012, at 12:55am, Keith Chew wrote: > > and I know FULL (1) will provide that. The question is why > > NORMAL (1) cannot provide the same. > > Because NORMAL doesn't flush changes to

Re: [sqlite] System.Data.SQLite and VS2012 RTM designer support

2012-09-10 Thread Browser IA
> > > > Does System.Data.SQLite support Visual Studio 2012 Ultimate RTM? > > > > Not yet. It might or might not be in the future. See: > > https://system.data.sqlite.org/index.html/doc/trunk/www/faq.wiki#q2 > I saw this in the FAQ, however it says nothing specific about support for VS 2012, or

Re: [sqlite] System.Data.SQLite and VS2012 RTM designer support

2012-09-10 Thread Joe Mistachkin
Browser IA wrote: > > Does System.Data.SQLite support Visual Studio 2012 Ultimate RTM? > Not yet. It might or might not be in the future. See: https://system.data.sqlite.org/index.html/doc/trunk/www/faq.wiki#q2 > > It was available in the 1.0.66 version - that version also had an

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Simon Slavin
On 11 Sep 2012, at 12:55am, Keith Chew wrote: > Durability means a transaction cannot be lost When is a transaction a transaction. Under the definition of ACID a transaction is a transaction as soon is your COMMIT returns with a non-error result code. > , and I know

[sqlite] System.Data.SQLite and VS2012 RTM designer support

2012-09-10 Thread Browser IA
Does System.Data.SQLite support Visual Studio 2012 Ultimate RTM? I ran the installation package (sqlite-netFx40-setup-bundle-x86-2010-1.0.82.0.exe). When I open up Visual Studio 2012 Ultimate, and navigate to "Server Explorer" and "Add Connection", under the "Data source" list SQLite is not

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Keith Chew
Hi Simon Thank you for your reply. > > Probably worth us knowing whether you've read the 'Performance > Considerations' section of > > > Yes, I have read that, along with all the threads/posts I could find from the Internet. The thing that I cannot fully

Re: [sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Simon Slavin
On 10 Sep 2012, at 9:00pm, Keith Chew wrote: > Using journal_mode=WAL and synchronous=2, it is my understanding (from > the docs and my own power loss testing) that sqlite will maintain > durability on a power loss. > > My question is, if sqlite can guarantee durability

[sqlite] WAL, synchronous=1 and durability

2012-09-10 Thread Keith Chew
Hi Using journal_mode=WAL and synchronous=2, it is my understanding (from the docs and my own power loss testing) that sqlite will maintain durability on a power loss. My question is, if sqlite can guarantee durability with synchronous=2, why can't it (from reading the docs and other posts) do

[sqlite] Registration Open for 19th Annual Tcl/Tk Conference (Tcl'2012)

2012-09-10 Thread Andreas Kupries
19th Annual Tcl/Tk Conference (Tcl'2012) http://www.tcl.tk/community/tcl2012/ November 12 - 16, 2012 Sessions: National Museum of Health and Medicine Chicago 175 W. Washington Chicago, IL 60602 Rooms: Holiday Inn Chicago Mart Plaza 350 West Mart Center Drive Chicago,

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Igor Tandetnik
On 9/10/2012 1:22 PM, kball...@kennethballard.com wrote: Here's one that I wrote a while back: void sqlite3_instr(sqlite3_context* pContext, int argc, sqlite3_value** argv) { const char *str1 = (const char *) sqlite3_value_text(argv[0]); const char *str2 = (const char *)

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Petite Abeille
On Sep 10, 2012, at 4:21 PM, Sébastien Roux wrote: > I'm looking for the[in]famous sqlite "*instr"* function which doesn't exist > (searched the web so far without success). Also searched for a > "*position"*function, without success too! > > Any idea or help? I found

Re: [sqlite] instr function or equivalent

2012-09-10 Thread kball...@kennethballard.com
Here's one that I wrote a while back: void sqlite3_instr(sqlite3_context* pContext, int argc, sqlite3_value** argv) { const char *str1 = (const char *) sqlite3_value_text(argv[0]); const char *str2 = (const char *) sqlite3_value_text(argv[1]); char *p = strstr(str1, str2); int

Re: [sqlite] EXTERNAL: Re: Error: no such access mode :memory

2012-09-10 Thread Sum, Eric B
Hi Simon, > Please tell us how you are specifying memory access mode. For instance, are > you using the URI string ? If so, can you post the string ? Or are you > passing ":memory:" along as a filename somewhere ? Thanks for such a quick response. I am using the URI string to specify

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Igor Tandetnik
On 9/10/2012 12:45 PM, Simon Slavin wrote: Similar but it only every has to (recursively) look at the rightmost character. 'instr' has to be able to look at substrings all the way along the string. So does replace(), which SQLite does implement. -- Igor Tandetnik

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Carlos Milon Silva
Hi, You could check the sqlite extensions from www.monkeybreadsoftware.de at: http://www.monkeybreadsoftware.de/SQLiteExtension/functions.shtml Best Regards, Carlos. Em 10/09/2012 10:21, Sébastien Roux escreveu: Hi, I'm looking for the[in]famous sqlite "*instr"* function which doesn't exist

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Simon Slavin
On 10 Sep 2012, at 5:43pm, Bart Smissaert wrote: > Yes, but doesn't rtrim do an instr function with the same problems as > you mention? Similar but it only every has to (recursively) look at the rightmost character. 'instr' has to be able to look at substrings all

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
Yes, but doesn't rtrim do an instr function with the same problems as you mention? RBS On 9/10/12, Simon Slavin wrote: > > On 10 Sep 2012, at 5:36pm, Bart Smissaert wrote: > >> Yes, you are right there. >> As rtrim incorporates an instr type of

Re: [sqlite] Error: no such access mode :memory

2012-09-10 Thread Simon Slavin
On 10 Sep 2012, at 5:24pm, esum wrote: > I am > getting the sqlite error "1: no such access mode :memory" in the following > two situations that I would like to implement. Please tell us how you are specifying memory access mode. For instance, are you using the URI

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Simon Slavin
On 10 Sep 2012, at 5:36pm, Bart Smissaert wrote: > Yes, you are right there. > As rtrim incorporates an instr type of function I am not sure why there > is no plain instr function in SQLite. It would make things a bit simpler. Two ways to add appropriate functions to

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
Yes, you are right there. As rtrim incorporates an instr type of function I am not sure why there is no plain instr function in SQLite. It would make things a bit simpler. RBS On 9/10/12, Black, Michael (IS) wrote: > It might be faster but it doesn't work for anybody

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Black, Michael (IS)
It might be faster but it doesn't work for anybody who has any letters in "from" in their name. sqlite> insert into t values('132|2012-09-07|Logging in user [tom] from [10.169.22.59]'); sqlite> select rtrim(s,' from [.0123456789]') || ']' from t; Logging in user [aa]

[sqlite] Error: no such access mode :memory

2012-09-10 Thread esum
Hi, I am using sqlite version 3.7.13 in a multithreaded application. I am getting the sqlite error "1: no such access mode :memory" in the following two situations that I would like to implement. I would like to get situation 1 working the most. 1. I open an in memory database with

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
This is slightly faster: select rtrim(s,' from [.0123456789]') || ']' from t RBS On 9/10/12, Bart Smissaert wrote: > Nice one! Works here. > > RBS > > > On 9/10/12, Black, Michael (IS) wrote: >> Does this work for you? >> >> SQLite version

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
Nice one! Works here. RBS On 9/10/12, Black, Michael (IS) wrote: > Does this work for you? > > SQLite version 3.7.13 2012-06-11 02:05:22 > Enter ".help" for instructions > Enter SQL statements terminated with a ";" > sqlite> create table t(s); > sqlite> insert into t

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Sébastien Roux
Enormous! Thanks it works! Sébastien Roux 2012/9/10 Black, Michael (IS) > Does this work for you? > > SQLite version 3.7.13 2012-06-11 02:05:22 > Enter ".help" for instructions > Enter SQL statements terminated with a ";" > sqlite> create table t(s); > sqlite> insert

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Black, Michael (IS)
Does this work for you? SQLite version 3.7.13 2012-06-11 02:05:22 Enter ".help" for instructions Enter SQL statements terminated with a ";" sqlite> create table t(s); sqlite> insert into t values('Logging in user [aa] from [10.165.69.247]'); sqlite> insert into t

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Sébastien Roux
Sad! Would you have any link toward SQLite's user defined SQLite function? Many thanks. Sébastien Roux 2012/9/10 Bart Smissaert > Ah, OK. I have a feeling that needs to be done either in your application > code > or with a user defined SQLite function. > Somebody

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
Ah, OK. I have a feeling that needs to be done either in your application code or with a user defined SQLite function. Somebody may prove me wrong. RBS On 9/10/12, Sébastien Roux wrote: > I want to remove/trim characters strating from "from" til "]" > > Logging in

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Sébastien Roux
I want to remove/trim characters strating from "from" til "]" Logging in user [aa] from [10.165.69.247] 194|2012-09-07|Logging in user [a] from [10.296.44.163] 160|2012-09-04|Logging in user [aaa] from [10.164.69.248] 136|2012-09-07|Logging in user [aaa] from [10.168.59.169]

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
Could your application supply the values in code? What exactly are you trying to do? RBS On 9/10/12, Sébastien Roux wrote: > Thanks Bart but substr require hard coded positions I guess, I need to get > this position dynamically! > > Sébastien Roux > > 2012/9/10 Bart

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Sébastien Roux
Thanks Bart but substr require hard coded positions I guess, I need to get this position dynamically! Sébastien Roux 2012/9/10 Bart Smissaert > http://www.sqlite.org/lang_corefunc.html > > Look at substr > > > RBS > > > On 9/10/12, Sébastien Roux

Re: [sqlite] instr function or equivalent

2012-09-10 Thread Bart Smissaert
http://www.sqlite.org/lang_corefunc.html Look at substr RBS On 9/10/12, Sébastien Roux wrote: > Hi, > > I'm looking for the[in]famous sqlite "*instr"* function which doesn't exist > (searched the web so far without success). Also searched for a >

[sqlite] instr function or equivalent

2012-09-10 Thread Sébastien Roux
Hi, I'm looking for the[in]famous sqlite "*instr"* function which doesn't exist (searched the web so far without success). Also searched for a "*position"*function, without success too! Any idea or help? I found some threads about custom functions but no tutorial nor deeper explanations! Many

Re: [sqlite] indexing for integer column

2012-09-10 Thread Durga D
Hi, Can I create INDEX for the particular column when database journal mode is WAL? Any impact If I INDEXed database with some triggers? Thanks in advance. Best Regards, On Thu, Sep 6, 2012 at 4:04 PM, Durga D wrote: > Thank you Kees. > > > On Thu, Sep 6, 2012

Re: [sqlite] Possible bug - journal_mode DELETE/TRUNCATE

2012-09-10 Thread Daniel Frimerman
Yes! The journal file was indeed there. I deleted it before openning the database, and read 50 records. I repeated the process; it's consistent. The way I see it that even though the synchronous setting is FULL, there is no API to tell the OS to physically delete a file from disk, just like