Re: [sqlite] Direct PostgreSQL to SQLite connection?

2013-09-26 Thread Vivien Malerba
Hi! Using Libgda (http://www.gnome-db.org) you can create virtual connections which "aggregate" several other connections (meaning all the tables from all the connections can be used in single SQL queries and you could copy data using an "INSERT INTO XXX SELECT ... FROM YYY" query), in your case

Re: [sqlite] Connection between SQLite - Other Databases

2013-06-20 Thread Vivien Malerba
Hi! You can check Libgda which allows you to open several connections (e.g. 1 for SQLite and 1 for Oracle), bind them together in different namespaces, and execute SQL code on all the bound connections at the same time. Regards, Vivien On 20 June 2013 06:34, Reddy C. balaji

Re: [sqlite] Building an SQL AST

2012-07-12 Thread Vivien Malerba
Le 12 juil. 2012 21:40, "Aaron Patterson" a écrit : > > Hi, > > I would like to build an AST of a SQL statement using SQLite3. I've > been reading through sqlite3RunParser as well as the grammar. It > *looks* like the grammar is building some sort of structure before

Re: [sqlite] Detecting when a table is created

2012-06-26 Thread Vivien Malerba
On 26 June 2012 15:31, Black, Michael (IS) wrote: > If you have sqlite3.c in your project you can just add your own hook. > > > > Take a look at sqlite3TwoPartName if you want to see if before it's > created. > > > > Or look at sqlite3StartTable (end of the function) if

Re: [sqlite] Detecting when a table is created

2012-06-26 Thread Vivien Malerba
On 26 June 2012 15:00, kyan wrote: > > Is there any possibility to be notified when a table is created (when a > > "CREATE TABLE XXX" is executed)? > > You could try installing a profile callback using sqlite3_profile() > (see http://www.sqlite.org/c3ref/profile.html). Of

Re: [sqlite] Detecting when a table is created

2012-06-26 Thread Vivien Malerba
On 26 June 2012 14:55, Simon Slavin <slav...@bigfraud.org> wrote: > > On 26 Jun 2012, at 1:33pm, Vivien Malerba <vmale...@gmail.com> wrote: > > > The code is some SQL entered by the user, I have no control over it. > There > > is effectively the possibil

Re: [sqlite] Detecting when a table is created

2012-06-26 Thread Vivien Malerba
On 26 June 2012 14:21, Igor Tandetnik <itandet...@mvps.org> wrote: > Vivien Malerba <vmale...@gmail.com> wrote: > > Is there any possibility to be notified when a table is created (when a > > "CREATE TABLE XXX" is executed)? > > How is it ex

[sqlite] Detecting when a table is created

2012-06-26 Thread Vivien Malerba
Hi! Is there any possibility to be notified when a table is created (when a "CREATE TABLE XXX" is executed)? The context here is that I have an SQLite connection with only virtual tables and when the user manually creates a table, the table is created either in memory or in the temporary file

Re: [sqlite] savepoint

2012-01-16 Thread Vivien Malerba
2012/1/16 Csaba Jeney > Is there any way to query the valid savepoints? At least their names? > Many thanks. > > AFAIK, the only way to do this is to keep track of each begin, rollback, add savepoint, ... executed, to always know where you are. (Anyway this is what's done in

Re: [sqlite] SQLite C - APIs to insert data in to a table.

2012-01-12 Thread Vivien Malerba
On 12 January 2012 12:22, bhaskarReddy wrote: > > Hi Friends, > > I am using SQLite. This is the first time. And i am creating, > accessing and retrieving data from the table. > > I am using sqlite3_exec() function to insert and retrieve data. > Instead using

Re: [sqlite] pragma foreign_key_list deprecated in 3.7.4?

2010-12-08 Thread Vivien Malerba
On 8 December 2010 20:44, Richard Hipp wrote: > On Wed, Dec 8, 2010 at 2:35 PM, Petite Abeille > wrote: > >> Hello, >> >> The pragma foreign_key_list appears to be deprecated in 3.7.4: >> >> http://www.sqlite.org/pragma.html#pragma_foreign_key_list >>

Re: [sqlite] virtual tables

2010-11-23 Thread Vivien Malerba
On 23 November 2010 17:39, Roger Binns <rog...@rogerbinns.com> wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > On 11/23/2010 02:04 AM, Vivien Malerba wrote: >> The Libgda library (http://www.gnome-db.org) uses virtual tables > > Are you sure?  It l

Re: [sqlite] virtual tables

2010-11-23 Thread Vivien Malerba
The Libgda library (http://www.gnome-db.org) uses virtual tables to enable one to execute statements on several tables from several database backends (SQlite, PostgreSQL, MySQL, Oracle, Jdbc, SqlCipher, MDB) and CSV files. Regards, Vivien ___

Re: [sqlite] gui for data entry

2010-10-12 Thread Vivien Malerba
On 12 October 2010 17:51, Graham Smith wrote: > There are several GUI editors for SQLite, but is there one that allows > creation of simple forms to allow data entry.  Although some allow > adding data to a single table, none that I have looked at seem to > allow a new record

Re: [sqlite] SQLite 3.7.0 coming soon....

2010-06-30 Thread Vivien Malerba
For what it's worth, I've just tested Libgda with the latest dev. version of the 3.7.0 and found no problem at all with the NR tests (note that Libgda uses a lot the virtual tables features). Thanks a lot for your very good work in SQlite! Regards, Vivien On 30 June 2010 19:21, D. Richard Hipp

Re: [sqlite] copy data from one db to another

2010-06-09 Thread Vivien Malerba
On 9 June 2010 20:44, Rich Shepard <rshep...@appl-ecosys.com> wrote: > On Wed, 9 Jun 2010, Vivien Malerba wrote: > >>> I forgot to mention, the source is a PostgreSQL db, not SQLite, so >>> there's no source file to copy.  Though a backup might be >>> intere

Re: [sqlite] copy data from one db to another

2010-06-09 Thread Vivien Malerba
On 9 June 2010 18:58, Scott Frankel <fran...@circlesfx.com> wrote: > > On Jun 9, 2010, at 12:22 AM, Vivien Malerba wrote: > >> On 8 June 2010 22:02, Scott Frankel <fran...@circlesfx.com> wrote: >>> >>> On Jun 8, 2010, at 12:51 PM, Jean-Christophe Descha

Re: [sqlite] copy data from one db to another

2010-06-09 Thread Vivien Malerba
On 8 June 2010 22:02, Scott Frankel wrote: > > On Jun 8, 2010, at 12:51 PM, Jean-Christophe Deschamps wrote: > >> >>> What's the best way to copy data from one db to another? >>> >>> Given 2 databases with identical schemas, one full of data and the >>> other empty, the

Re: [sqlite] Export sqlite database to H2

2010-04-09 Thread Vivien Malerba
On 9 April 2010 13:37, Andreas Henningsson wrote: > Hi > > I am about to change database from SQLite to H2 in a project of mine. > > Is there any tools I can use to do i it? What is the best way to export data > from an SQLite database? > The easiest is probably

Re: [sqlite] Parsing create statements

2010-01-21 Thread Vivien Malerba
> BareFeet wrote: >> At the moment I am resorting to developing regular expressions to do the >> parsing. They work, but it seems to be re-inventing the wheel. > > You won't be able to do parsing completely with regular expressions.  Create > statements let you specify default values for a column

Re: [sqlite] Sqlite3 is not compiling in Linux

2009-04-14 Thread Vivien Malerba
2009/4/14 Pramoda M. A > What I have done is, > > Cc -lpthread sqlite3.o ourApplication.o -o main > > Then it is giving linker error. Is it right? try instead: cc -lpthread -ldl sqlite3.o ourApplication.o -o main Vivien

Re: [sqlite] Sqlite3 is not compiling in Linux

2009-04-14 Thread Vivien Malerba
2009/4/14 Pramoda M. A > Hi All, > > > > I tried to compile in Linux. But it is giving error at linking stage as > 'unreferenced dlopne dlclose... > > Can anybody help me? did you add the -ldl linker flag? Vivien ___

[sqlite] Unsigned int 64 in WHERE

2009-02-27 Thread Vivien Malerba
Hi! I have a table with a timestamp column which I use to insert sqlite_uint64 values using sqlite3_bind_int64() (values are retreived using sqlite3_column_int64() with a cast to sqlite_uint64). This works fine with the C API. The problem is that when I try to use the sqlite3 command line, if I

Re: [sqlite] journal_mode = off crash in 3.6.10

2009-02-04 Thread Vivien Malerba
This has already been fixed, see http://www.sqlite.org/cvstrac/tktview?tn=3603 Regards, Vivien 2009/2/4 Brodie Thiesfield > Hi, > > I know that there has been a number of crashes involving > journal_mode = off. This problem continues for me in > sqlite 3.6.10

Re: [sqlite] file structure issue

2007-05-23 Thread Vivien Malerba
On 5/23/07, weiyang wang <[EMAIL PROTECTED]> wrote: hi, i can see the source file structure has been changed from 65 (sqliteint.h, os_common.h,. )files before to only 2 files (sqlite3.h)now. and this change bring me a problem when i try to integrate sqlite with other platforms. in my

Re: [sqlite] Multiple connections to the same database and CREATE TABLE command

2007-05-11 Thread Vivien Malerba
On 5/11/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: "Vivien Malerba" <[EMAIL PROTECTED]> wrote: > Hi! > > In a single process, I open two connections (C1 and C2) to the same > database (this is actually a corner case which could happen) and the > follo

[sqlite] Multiple connections to the same database and CREATE TABLE command

2007-05-11 Thread Vivien Malerba
Hi! In a single process, I open two connections (C1 and C2) to the same database (this is actually a corner case which could happen) and the following sequence of operations fail: 1- on C1 execute "CREATE table actor (...)" => Ok 2- on C1 execute "SELECT * FROM actor" => Ok 3- on C2 execute

Re: [sqlite] Error reporting problem

2007-03-26 Thread Vivien Malerba
On 3/26/07, Martin Jenkins <[EMAIL PROTECTED]> wrote: Vivien Malerba wrote: > Hi! > > I've got an error reporting problem when trying to insert a row which > breaks a UNIQUE constraint in a table in a C program, I get the > following error with sqlite3_errmsg(): > &qu

[sqlite] Error reporting problem

2007-03-26 Thread Vivien Malerba
Hi! I've got an error reporting problem when trying to insert a row which breaks a UNIQUE constraint in a table in a C program, I get the following error with sqlite3_errmsg(): "SQL logic error or missing database" If I fire the sqlite3 program and run the same SQL query, I get the following

Re: [sqlite] Pragma table_info(), why no fields like UNIQUE, AUTOINCREMENT

2007-03-13 Thread Vivien Malerba
On 3/13/07, Martin Jenkins <[EMAIL PROTECTED]> wrote: Vivien Malerba wrote: > I've already sent a proposal along with a patch some time ago about > that, but nobody seemed to care, see > http://www.mail-archive.com/sqlite-users@sqlite.org/msg21285.html Vivien, I can't see any

Re: [sqlite] Pragma table_info(), why no fields like UNIQUE, AUTOINCREMENT

2007-03-13 Thread Vivien Malerba
On 3/12/07, Stef Mientki <[EMAIL PROTECTED]> wrote: If ask the table sturcture, with pragma table_info() I get of course the basic fields, like: CID,Name,Type, And also SOME special values, like Null, DefaultValue, PrimaryKey But NOT the following special values (and probably a lot more)

[sqlite] Need for new pragma directives

2007-01-22 Thread Vivien Malerba
Hi! My project (Libgda/Libgnomedb) needs to be able to get more information about a database structure, and I've made a patch which defines 3 new pragma directives: * "table_info_long()" which adds a column to the "table_info" pragma to tell if a column is auto incremented (see ticket #1464) *

Re: [sqlite] Handling null characters in blob data

2006-11-16 Thread Vivien Malerba
On 11/15/06, John Stanton <[EMAIL PROTECTED]> wrote: Vivien Malerba wrote: > On 11/13/06, Shivshankar Subramani - TLS , Chennai <[EMAIL PROTECTED]> > wrote: > >> Hi all, >> >> > SQLite version 2.8 and earlier could not (easily) store binary >> &g

Re: [sqlite] Handling null characters in blob data

2006-11-15 Thread Vivien Malerba
On 11/13/06, Shivshankar Subramani - TLS , Chennai <[EMAIL PROTECTED]> wrote: Hi all, > SQLite version 2.8 and earlier could not (easily) store binary > data - data with embedded \000 characters. Thus the encode/decode > routines were provide to transform data so that it contained no > \000

Re: [sqlite] Wish to store a C structure in sqlite column

2006-09-22 Thread Vivien Malerba
On 9/22/06, AJ <[EMAIL PROTECTED]> wrote: I hackish method might be something like this: struct s { ... }; struct s myS; char buf[sizeof(s)*2]; // *2 as base64 encoding will be approx 33% bigger. base64_encode( , buf, sizeof(s) ); INSERT INTO table ( myTextField ) VALUES ( 'buf' );

Re: [sqlite] HexValues

2006-09-13 Thread Vivien Malerba
On 9/12/06, guy12 <[EMAIL PROTECTED]> wrote: hi, i need to insert hex values in the data base and after that i have to select them again ... what's the best way for doing that ?? i first used INTERGER for that but i think that is the wrong way... p.s. i need to accress the db through my

Re: [sqlite] need to form an frame work for database independent API

2006-08-31 Thread Vivien Malerba
On 8/18/06, Narendran <[EMAIL PROTECTED]> wrote: I wish to form an database independant API for sqlite and BerkeleyDB . I need to now wht factors should consider . i am new to both . I have problems in running an simple program in sqlite . its say can't find the sqlite3_open( . If i paste

[sqlite] Re: Patch proposal

2005-09-28 Thread Vivien Malerba
2005/9/28, Vivien Malerba <[EMAIL PROTECTED]>: > Hi! > > Here is a small patch which modifies the returned data set of the > PRAGMA table_info() to add a new column named "auto_inc" which > contains 1 if the corresponding field has the AUTO INCREMENT in its > def

Re: [sqlite] Schemas

2005-09-28 Thread Vivien Malerba
2005/9/28, Firman Wandayandi <[EMAIL PROTECTED]>: > On 9/27/05, Vivien Malerba <[EMAIL PROTECTED]> wrote: > > Hi! > > > > I'm working on the SQLite interface between the Libgda library and the > > SQLite database. For the job, I need to know information about

[sqlite] Schemas

2005-09-27 Thread Vivien Malerba
Hi! I'm working on the SQLite interface between the Libgda library and the SQLite database. For the job, I need to know information about the database schema, and I'm using the PRAGMA statements regarding schemas. However I can't find the information about the AUTO INCREMENT attribute of a