Re: [sqlite] SQLite and C++

2012-06-13 Thread PJ Naughter
-Original Message- From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Arbol One Sent: 13 June 2012 12:22 To: SQLite user list Users Subject: [sqlite] SQLite and C++ Anyone knows where I can find some examples of how C++ interfaces with SQLite? I just need

Re: [sqlite] SQLite and C++

2012-06-13 Thread Simon Slavin
On 13 Jun 2012, at 12:21pm, "Arbol One" <arbol...@programmer.net> wrote: > Anyone knows where I can find some examples of how C++ interfaces with > SQLite? I just need to see some code that is functional and not just some > snips of how it maybe-should-possibly work

Re: [sqlite] SQLite and C++

2012-06-13 Thread John Drescher
On Wed, Jun 13, 2012 at 7:21 AM, Arbol One <arbol...@programmer.net> wrote: > Anyone knows where I can find some examples of how C++ interfaces with > SQLite? I just need to see some code that is functional and not just some > snips of how it maybe-should-possibly w

Re: [sqlite] SQLite and C++

2012-06-13 Thread Stephan Beal
On Wed, Jun 13, 2012 at 1:21 PM, Arbol One <arbol...@programmer.net> wrote: > Anyone knows where I can find some examples of how C++ interfaces with > SQLite? I just need to see some code that is functional and not just some > snips of how it maybe-should-possibly work. >

[sqlite] SQLite and C++

2012-06-13 Thread Arbol One
Anyone knows where I can find some examples of how C++ interfaces with SQLite? I just need to see some code that is functional and not just some snips of how it maybe-should-possibly work. TIA ___ sqlite-users mailing list sqlite-users@sqlite.org http

Re: [sqlite] sqlite Commit C API

2012-05-21 Thread Simon Slavin
On 21 May 2012, at 12:22pm, "Black, Michael (IS)" wrote: > I'll have to check the BIOS settings on my box and see if turning off write > caching makes more sense on that particular test. That won't do any harm, but you should be aware that your hardware lies. Some

Re: [sqlite] sqlite Commit C API

2012-05-21 Thread Black, Michael (IS)
Tandetnik [itandet...@mvps.org] Sent: Sunday, May 20, 2012 8:47 AM To: sqlite-users@sqlite.org Subject: EXT :Re: [sqlite] sqlite Commit C API Black, Michael (IS) <michael.bla...@ngc.com> wrote: > Hmmm...our math is a bit different... > > A 1,000 RPM disk would take 1ms to s

Re: [sqlite] sqlite Commit C API

2012-05-20 Thread Jay A. Kreibich
On Sun, May 20, 2012 at 01:26:48PM +, Black, Michael (IS) scratched on the wall: > Hmmm...our math is a bit different... Yeah, your math is wrong... 8-) > A 1,000 RPM disk would take 1ms to spin around once A 1,000 RPS disk would, but not a 1,000 RPM disk. > I believe my original

Re: [sqlite] sqlite Commit C API

2012-05-20 Thread Igor Tandetnik
Black, Michael (IS) wrote: > Hmmm...our math is a bit different... > > A 1,000 RPM disk would take 1ms to spin around once No it wouldn't. > (there are 1000ms in a second, correct?) Yes, but RPM stands for a revolution-per-*minute*. You are off by a factor of 60. --

Re: [sqlite] sqlite Commit C API

2012-05-20 Thread Black, Michael (IS)
of Jay A. Kreibich [j...@kreibi.ch] Sent: Sunday, May 20, 2012 7:53 AM To: General Discussion of SQLite Database Subject: EXT :Re: [sqlite] sqlite Commit C API On Sun, May 20, 2012 at 12:04:33PM +, Black, Michael (IS) scratched on the wall: > Another more indirect way to test is this util

Re: [sqlite] sqlite Commit C API

2012-05-20 Thread Jay A. Kreibich
On Sun, May 20, 2012 at 12:04:33PM +, Black, Michael (IS) scratched on the wall: > Another more indirect way to test is this utility: > > http://kerneltrap.org/mailarchive/linux-ext4/2009/3/22/5215824 > > Which...if your fsync doesn't work at all will return something really > close to

Re: [sqlite] sqlite Commit C API

2012-05-20 Thread Black, Michael (IS)
If you can run perl on your ARM host try this utility to see if fsync() actually works -- this is a real end-to-end test that you pull the plug on and it will let you know if your disk file is where it's supposed to be and how many errors you had. http://brad.livejournal.com/2116715.html

Re: [sqlite] sqlite Commit C API

2012-05-20 Thread Baruch Burstein
> On Thu, May 17, 2012 at 7:04 PM, Rajesh Kumar wrote: > int fsync( int fd ) { return 0; } > > fsync will expect an Integer pointer right. But sqlite pointer is of type > sqlite3*. So how can fsync works on sqlite. What should I pass to fsync??? > > You don't need to call

Re: [sqlite] sqlite Commit C API

2012-05-18 Thread Christian Smith
On Thu, May 17, 2012 at 04:47:29PM +0100, Simon Slavin wrote: > > On 17 May 2012, at 4:34pm, Rajesh Kumar wrote: > > > No am not using any PRAGMAs. I just cross compiled sqlite source to > > ARM architecture. Can't I forcefully do commit on my transaction > > If you

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Marc L. Allen
Subject: Re: [sqlite] sqlite Commit C API On 17 May 2012, at 4:49pm, Jay A. Kreibich <j...@kreibi.ch> wrote: > I wouldn't be all that shocked to find out an embedded system has an > fsync() call that looks like this: > > int fsync( int fd ) { return 0; } We are best soft

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Simon Slavin
On 17 May 2012, at 5:04pm, Rajesh Kumar wrote: > int fsync( int fd ) { return 0; } > > fsync will expect an Integer pointer right. But sqlite pointer is of type > sqlite3*. So how can fsync works on sqlite. What should I pass to fsync??? Sorry Rajesh. It was a

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Rajesh Kumar
int fsync( int fd ) { return 0; } fsync will expect an Integer pointer right. But sqlite pointer is of type sqlite3*. So how can fsync works on sqlite. What should I pass to fsync??? On Thu, May 17, 2012 at 9:19 PM, Jay A. Kreibich wrote: > int fsync( int fd ) { return 0; }

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Simon Slavin
On 17 May 2012, at 4:49pm, Jay A. Kreibich wrote: > I wouldn't be all that shocked to find out an embedded system has an > fsync() call that looks like this: > > int fsync( int fd ) { return 0; } We are best software circle ! Our programmers write many functions a day !

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Jay A. Kreibich
On Thu, May 17, 2012 at 08:58:39PM +0530, Rajesh Kumar scratched on the wall: > Hi Richard, > > Thanks for the reply. fsync() is related to system call, which is > working fine. I believe you're missing Richard's point. I'm sure fsync() is returning a success error code. That doesn't

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Simon Slavin
On 17 May 2012, at 4:34pm, Rajesh Kumar wrote: > No am not using any PRAGMAs. I just cross compiled sqlite source to > ARM architecture. Can't I forcefully do commit on my transaction If you are correctly using _open() and _close(), and haven't disabled synchrony with

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Rajesh Kumar
So if I use _exec() after sqlit3_exec() API, what ever the I did on database will be saved, right?? On Thu, May 17, 2012 at 9:03 PM, Simon Slavin wrote: > > On 17 May 2012, at 4:28pm, Rajesh Kumar wrote: > > >Thanks for the reply. fsync() is

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Rajesh Kumar
No am not using any PRAGMAs. I just cross compiled sqlite source to ARM architecture. Can't I forcefully do commit on my transaction On Thu, May 17, 2012 at 8:55 PM, Simon Slavin wrote: > > On 17 May 2012, at 4:18pm, Rajesh Kumar wrote: > > > Am

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Simon Slavin
On 17 May 2012, at 4:28pm, Rajesh Kumar wrote: >Thanks for the reply. fsync() is related to system call, which is > working fine. But I am looking for a C API that can do the commit thing, > which is same as commit on command promt. The COMMIT; on a command prompt

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Rajesh Kumar
Hi Richard, Thanks for the reply. fsync() is related to system call, which is working fine. But I am looking for a C API that can do the commit thing, which is same as commit on command promt. On Thu, May 17, 2012 at 8:52 PM, Richard Hipp wrote: > On Thu, May 17, 2012 at

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Jay A. Kreibich
On Thu, May 17, 2012 at 11:22:44AM -0400, Richard Hipp scratched on the wall: > On Thu, May 17, 2012 at 11:18 AM, Rajesh Kumar wrote: > > > Hi all, > > > >Am using sqlite database on my ARM processor based Embedded system . > > Whenever power failures or due to uneven

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Simon Slavin
On 17 May 2012, at 4:18pm, Rajesh Kumar wrote: > Am using sqlite database on my ARM processor based Embedded system . > Whenever power failures or due to uneven shutdown of device, my database > is being corrupted which leading to data lost. Am using C API interface for >

Re: [sqlite] sqlite Commit C API

2012-05-17 Thread Richard Hipp
On Thu, May 17, 2012 at 11:18 AM, Rajesh Kumar wrote: > Hi all, > >Am using sqlite database on my ARM processor based Embedded system . > Whenever power failures or due to uneven shutdown of device, my database > is being corrupted which leading to data lost. That

[sqlite] sqlite Commit C API

2012-05-17 Thread Rajesh Kumar
Hi all, Am using sqlite database on my ARM processor based Embedded system . Whenever power failures or due to uneven shutdown of device, my database is being corrupted which leading to data lost. Am using C API interface for accessing database. Is there any C API that I can use to commit my

Re: [sqlite] SQLite and C++ in Linux

2010-10-07 Thread Richard Hipp
On Thu, Oct 7, 2010 at 5:47 PM, Dan Sabin <dan.sa...@gmail.com> wrote: > Hi, > > I'm trying to embed SQLite into a Linux application. It's written in C++ > and I'm having trouble getting the code to compile with the SQLite .c and .h > files included. I get some of

Re: [sqlite] SQLite in C# .NET

2009-11-11 Thread Robert Simpson
@sqlite.org Subject: [sqlite] SQLite in C# .NET Hi guys, I am trying to do a small GIS for a mobile application. My application is targeting Windows Mobile 6 Professional Edition. I am using CF 3.5 of .NET. I have included the .dll from here: http://freefr.dl.sourceforge.net/project/sqlite-dotnet2

[sqlite] SQLite in C# .NET

2009-11-11 Thread Matthew Pulis
Hi guys, I am trying to do a small GIS for a mobile application. My application is targeting Windows Mobile 6 Professional Edition. I am using CF 3.5 of .NET. I have included the .dll from here:

Re: [sqlite] SQLite under c++

2008-07-24 Thread Igor Tandetnik
"Juzbrig" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Ok it works but how do I get messages/errors back from DB? Because > now im doing it blind. You check return value for error code. If you got one, you call sqlite3_errmsg[16] for an error message. Igor Tandetnik

Re: [sqlite] SQLite under c++

2008-07-24 Thread Juzbrig
ED] On Behalf Of Juzbrig > Sent: 23 July 2008 13:31 > To: sqlite-users@sqlite.org > Subject: [sqlite] SQLite under c++ > > > Hi. > I am new in sqlite (before I have mysql + php experience). I have a > question > > If my DB is alredy open > > sqlite3* handle; &

Re: [sqlite] SQLite under c++

2008-07-23 Thread Igor Tandetnik
Juzbrig <[EMAIL PROTECTED]> wrote: > I am new in sqlite (before I have mysql + php experience). I have a > question If my DB is alredy open > > sqlite3* handle; > const char* baza = "cols.db3" ; > char *zErrMsg = 0; > sqlite3_open(test_baza,); > > How can I get the results of SQL "SELECT * FROM"

Re: [sqlite] SQLite under c++

2008-07-23 Thread Mike Marshall
3_finalize(pStatement); -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Juzbrig Sent: 23 July 2008 13:31 To: sqlite-users@sqlite.org Subject: [sqlite] SQLite under c++ Hi. I am new in sqlite (before I have mysql + php experience). I have a question If my DB

[sqlite] SQLite under c++

2008-07-23 Thread Juzbrig
or any c++ structure ? sqlite3_exec() doesn't seem to return any strings/chars. If anyone could write me that in code I would be grateful. -- View this message in context: http://www.nabble.com/SQLite-under-c%2B%2B-tp18609682p18609682.html Sent from the SQLite mailing list a

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-17 Thread Wilson, Ron P
10:55 AM To: sqlite-users@sqlite.org Subject: Re: [sqlite] SQlite and C works with "like" but not with "=" "Daniel White" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >> Which way is it stored in the database? Show the output of this >&g

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-16 Thread Daniel White
Thanks again Dan and Igor. Since I don't need to write to the database (only read from it atm), collate binary will do nicely. I'll keep an eye on those error messages in future! Dan On Sun, 15 Jun 2008 09:13:52 +0100, Dan <[EMAIL PROTECTED]> wrote: > On Jun 15, 2008, at 8:55 AM, Daniel White

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-15 Thread Dan
On Jun 15, 2008, at 8:55 AM, Daniel White wrote: > Cheers both of you, it seems this problem is indeed > linked with the "no such collation sequence: iunicode" > error as Dan mentioned. > > After some research, I found out that the root of > the problem is unsurmountable at present. I quote

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Igor Tandetnik
"Daniel White" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Oh well, there are one or two 'hacks' around it. The first is > to use COLLATE BINARY, or COLLATE NOCASE after the SQL query. > This appears okay on the surface, but probably ignores > unicode chars or something. It may

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Daniel White
Cheers both of you, it seems this problem is indeed linked with the "no such collation sequence: iunicode" error as Dan mentioned. After some research, I found out that the root of the problem is unsurmountable at present. I quote from: http://www.mediamonkey.com/forum/viewtopic.php?p=84197

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Dan
On Jun 14, 2008, at 9:08 PM, Daniel White wrote: > The course of action I thought you implied was to change > it from "hexion" to "Hexion", and so I hoped that would > return the results, but it still doesn't. > > "Still" meaning, just like the small 'h', 'H' doesn't > work either. > The answer

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Daniel White
> Which way is it stored in the database? Show the output of this > statement: > > SELECT SongTitle FROM songs WHERE SongTitle like 'hexion'; There are 8 records of Hexion in the database, so after a printout to the console with a carriage return after each value, I basically get: Hexion Hexion

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Igor Tandetnik
"Daniel White" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > The course of action I thought you implied was to change > it from "hexion" to "Hexion", and so I hoped that would > return the results, but it still doesn't. Which way is it stored in the database? Show the output of

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Daniel White
The course of action I thought you implied was to change it from "hexion" to "Hexion", and so I hoped that would return the results, but it still doesn't. "Still" meaning, just like the small 'h', 'H' doesn't work either. Dan also mentioned the capital letter thing so it was a reply to him as

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Igor Tandetnik
"Daniel White" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Funny you should mention the capital at the start > to make "Hexion". I thought of that just after I > posted. But it doesn't solve the problem unfortunately. > Zero results are still returned. What do you mean, "still"

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-14 Thread Daniel White
Thanks Dan and Igor for clarifying the 5th param. I'm guessing it's safe to leave it at 0 if I just use one SQL statement then. Funny you should mention the capital at the start to make "Hexion". I thought of that just after I posted. But it doesn't solve the problem unfortunately. Zero results

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-13 Thread Dan
On Jun 14, 2008, at 10:39 AM, Daniel White wrote: > Hi guys, > > My first post to this list, and I'm new to SQL in general too. > > Just a couple of questions to start: > > ***1: > In the sqlite3_prepare_v2 function, can someone explain > to me the 5th parameter better than the site's help can?

Re: [sqlite] SQlite and C works with "like" but not with "="

2008-06-13 Thread Igor Tandetnik
"Daniel White" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > My first post to this list, and I'm new to SQL in general too. > > Just a couple of questions to start: > > ***1: > In the sqlite3_prepare_v2 function, can someone explain > to me the 5th parameter better than the site's

[sqlite] SQlite and C works with "like" but not with "="

2008-06-13 Thread Daniel White
Hi guys, My first post to this list, and I'm new to SQL in general too. Just a couple of questions to start: ***1: In the sqlite3_prepare_v2 function, can someone explain to me the 5th parameter better than the site's help can? I quote: /* OUT: Pointer to unused portion of zSql */ I'm a bit

Re: [sqlite] sqlite with C++

2007-11-26 Thread Andreas Volz
Am Mon, 26 Nov 2007 08:36:47 -0500 (EST) schrieb Clay Dowling: > > Andreas Volz wrote: > > Am Sun, 25 Nov 2007 12:11:50 +0100 schrieb Andreas Volz: > > > >> Hello, > >> > >> I used this minimal example code to test my sqlite connection. This > >> works without problems. But now I tried to move

Re: [sqlite] sqlite with C++

2007-11-26 Thread Clay Dowling
Andreas Volz wrote: > Am Sun, 25 Nov 2007 12:11:50 +0100 schrieb Andreas Volz: > >> Hello, >> >> I used this minimal example code to test my sqlite connection. This >> works without problems. But now I tried to move the 'db' variable into >> the private member section of my 'Cache' class to

Re: [sqlite] sqlite with C++

2007-11-25 Thread Andreas Volz
Am Sun, 25 Nov 2007 12:11:50 +0100 schrieb Andreas Volz: > Hello, > > I used this minimal example code to test my sqlite connection. This > works without problems. But now I tried to move the 'db' variable into > the private member section of my 'Cache' class to access it from > various member

[sqlite] sqlite with C++

2007-11-25 Thread Andreas Volz
Hello, I used this minimal example code to test my sqlite connection. This works without problems. But now I tried to move the 'db' variable into the private member section of my 'Cache' class to access it from various member functions. That's all. I would assume that this makes no difference.

Re: [sqlite] Sqlite and C

2004-10-29 Thread Florian Boor
Hi, > Someone have a link about little software like an address book > write in ansi C with sqlite? look at http://gpe.handhelds.org most of the applications that need to store data use sqlite. e.g. gpe-contacts and gpe-todo (The database interface of it is in libtododb.) Greetings F

[sqlite] Sqlite and C

2004-10-29 Thread Max
Someone have a link about little software like an address book write in ansi C with sqlite? Thanks 1K Ciao Max -- Secondo alcuni autorevoli testi di tecnica Aeronautica, il calabrone non può volare, a causa della forma e del peso del proprio corpo in rapporto alla superficie alare. Ma il