that's the hard way:
open db1
attach db2
insert into db2.destinationTable select * from db1.sourceTable
done
On 9/15/06, Kevin Stewart <[EMAIL PROTECTED]> wrote:
I need to move some records from one database (and table) to another.
The tables are identical. My idea was to 'select' all
I need to move some records from one database (and table) to another.
The tables are identical. My idea was to 'select' all records that match
my search criteria and in the callback that is called from sqlite_exec()
I can add them to the other table in the other database. This way I
don't need
Downey, Shawn wrote:
Does anyone know if it is possible to determine if data is string or
numeric inside a callback in C++? I am using sqlite 3.2.7.
Unless you have some requirements that your code be compatible with
SQLite 2.*, I'd suggest you rewrite it to use the prepare/step
interface;
"Downey, Shawn" <[EMAIL PROTECTED]> wrote:
> Does anyone know if it is possible to determine if data is string or
> numeric inside a callback in C++? I am using sqlite 3.2.7.
>
sqlite3_exec() converts everything to a string before the callback
is invoked, of course. You could modify the
Does anyone know if it is possible to determine if data is string or
numeric inside a callback in C++? I am using sqlite 3.2.7.
Background:
A table with no data type specified for a field may be populated with an
unquoted number. For example:
create table t1 (a);
insert into t1
Doug Nebeker <[EMAIL PROTECTED]>
wrote:
I have a small number of read and writer threads. A few months ago I
had some deadlock issues and one simple solution was to run all
transactions as exclusive (ie BEGIN EXCLUSIVE). That works
perfectly--no hint of deadlock. But now that I've been using
John O'Neill wrote:
Hi Dennis,
Thanks for the reply. In the original "INSERT" commands, my intention was to update a field in the
columns as they were being copied to the new table. Sorry, I didn't mean just "SELECT ... WHERE
id=1" as the only condition...I'd like to select those items and
O'Neill [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 17, 2005 3:48 PM
To: sqlite-users@sqlite.org
Subject: RE: [sqlite] Is this possible in SQLite?
Hi Dennis,
Thanks for the reply. In the original "INSERT" commands, my intention
was to update a field in the columns as they were be
I guess this question is can I combine an UPDATE...SET with an INSERT...SELECT
command?
Thanks,
John
-Original Message-
From: Dennis Cote [mailto:[EMAIL PROTECTED]
Sent: Thursday, March 17, 2005 4:32 PM
To: sqlite-users@sqlite.org
Subject: Re: [sqlite] Is this possible in SQLite?
John O'
John O'Neill wrote:
Hello all,
I have a fairly simple DB with two tables. I'm trying to combine a SELECT and
UPDATE command, if it is possible:
CREATE TABLE a (id PRIMARY KEY, data INT);
CREATE TABLE b (id INT, data INT);
INSERT INTO a VALUES( 1, 100 );
INSERT INTO b VALUES( 1, 101 );
INSERT
> Is there a way to do the following:
>
> INSERT INTO acopy SELECT * FROM a WHERE id = 1 ( SET id = some value X );
> INSERT INTO bcopy SELECT * FROM b WHERE id = 1 ( SET id = X );
http://www.sqlite.org/lang_insert.html
sql-statement ::= INSERT [OR conflict-algorithm] INTO
Hello all,
I have a fairly simple DB with two tables. I'm trying to combine a SELECT and
UPDATE command, if it is possible:
CREATE TABLE a (id PRIMARY KEY, data INT);
CREATE TABLE b (id INT, data INT);
INSERT INTO a VALUES( 1, 100 );
INSERT INTO b VALUES( 1, 101 );
INSERT INTO b VALUES( 1,
I have a CREATE TABLE sql command with DEFAULT values. I would like
to BIND the default values, but it seems it is not supported. Is this
so?
I am using SQLITE3..
Any help appreciated.
Randall Fox
Paul Smith wrote:
If I do pragma integrity_check on a database I get:
*** in database main ***
On page 8 cell 0: invalid page number 1581
SQL error: database disk image is malformed
---
Is there any way to "fix" this (even if some data is lost), or does it
just need throwing away and restoring
If I do pragma integrity_check on a database I get:
*** in database main ***
On page 8 cell 0: invalid page number 1581
On page 8 at right child: invalid page number 1582
On page 7 cell 0: invalid page number 593
On page 7 cell 1: invalid page number 594
On page 7 cell 2: invalid page number 1171
401 - 415 of 415 matches
Mail list logo