Great suggestion!
I wonder however how should I implement it though... I am upserting tens of
millions of rows in chunks of several hundreds thousands (naturally I can't
do all this in memory). SQLite tutorial says if each update/insert is not
resulting in transaction, it can make up to 50k update
On Wed, Mar 11, 2009 at 11:08 PM, jonwood wrote:
>
>
> Doug Currie-2 wrote:
>>
>> Note the '/'s
>>
>
> What does this mean? What does DATE('2009-1-1') or DATE('2009/1/1') return?
> Does DATE() simply have no effect whatsoever?
> --
why don't you try it? See below --
[07:42 PM] ~/Projects$sqlite
On Mar 12, 2009, at 12:08 AM, jonwood wrote:
> Doug Currie-2 wrote:
>>
>> Note the '/'s
>>
>
> What does this mean? What does DATE('2009-1-1') or DATE('2009/1/1')
> return?
> Does DATE() simply have no effect whatsoever?
Sorry to be cryptic.
sqlite> select date('2009/12/03');
sqlite> select
Doug Currie-2 wrote:
>
> Note the '/'s
>
What does this mean? What does DATE('2009-1-1') or DATE('2009/1/1') return?
Does DATE() simply have no effect whatsoever?
--
View this message in context:
http://www.nabble.com/Query-Doesn%27t-Find-Record-tp22469520p22469578.html
Sent from the SQLite
On Mar 12, 2009, at 12:01 AM, jonwood wrote:
> PaymentDate=2009/01/05
Note the '/'s
> And then I ran the following query:
>
> SELECT * FROM Payments WHERE FK_CustomerID=5 AND DATE(PaymentDate) >=
> DATE('2009-01-01') AND DATE(PaymentDate) <= DATE('2009-03-11')
Note the '-'s.
'2009/' > '2009-'
Okay, so SQLite stores dates as strings, for whatever reason. I thought I had
this figured out but now I'm running into the following problem:
I have a table called Payments that contains a single row of data with the
following values:
PaymentID=1
FK_CustomerID=5
PaymentDate=2009/01/05
PaymentTy
On 12/03/2009, at 12:36 PM, Jean-Christophe Deschamps wrote:
>
> To answer another post by Ian, yes I've had a look at ICU. Of course
> ICU knows about its size, but what can they do about it, since their
> goal is to implement the most complete support possible?
Make parts of it be possible to
On 12/03/2009 1:36 PM, Jean-Christophe Deschamps wrote:
>
> BTW locales are far from perfection. For instance: you have to search
> text, say an address book in a cellphone, with FTS3 and you know the
> base may have words or names in a dozen european languages. How would
> you do? ICU? Huge
Roger Binns wrote:
> Jean-Christophe Deschamps wrote:
>
>> I'd like to have the group opinion about a feature I would find utterly
>> useful in _standard_ SQLite.
>>
>
> You are aware that "standard" SQLite is used in devices with a few
> kilobytes of memory through workstations and server
Roger,
>You are aware that "standard" SQLite is used in devices with a few
>kilobytes of memory through workstations and servers with gigabytes of it!
That's precisely why such approach is interesting!
>As far as I can tell you want some extra "standard" collation sequences
>and propose shor
REPKA_Maxime_NeufBox wrote:
> ->> Why is it possible to change data not defined in the constraint :
> Exemple : enter TEXT if the column is INTERGER ??
> enter 25 caracters if column is declared VARCHAR(15) ??
> I thought i will get an error return
> See exemple below :
>
>
As
sorka wrote:
> I can't for the life of me figure this out. I'm trying to do a nested select
> like this:
>
> SELECT x FROM (( UNION ) INTERSECT ( UNION
> )) WHERE X=
>
> Each of the select a through d statements all return the same column x. If I
> remove the inner parentheses, it executes just fin
On 12/03/2009, at 8:15 AM, Jean-Christophe Deschamps wrote:
>
> I feel the need for a different implementation of collating support.
> Not every user of SQLite needs full universal collating support à la
> ICU. It's huge and slows things down significantly.
This may be a dumb question, but why n
Jean-Christophe Deschamps wrote:
> I'd like to have the group opinion about a feature I would find utterly
> useful in _standard_ SQLite.
You are aware that "standard" SQLite is used in devices with a few
kilobytes of memory through workstations and servers with gigabytes of it!
As far as I can
Hello group,
I'd like to have the group opinion about a feature I would find utterly
useful in _standard_ SQLite.
Here's a rewrite of mails sent to hwaci about it, without success so far.
Note: I guess that non pure ASCII characters in the sample strings
below will translate to '?', but you c
-Original Message-
From: sqlite-users-boun...@sqlite.org
[mailto:sqlite-users-boun...@sqlite.org] On Behalf Of Trainor, Chris
Sent: Wednesday, March 11, 2009 5:31 PM
To: General Discussion of SQLite Database
Subject: Re: [sqlite] Slow performance with Sum function
> Do not be tempted by
> Do not be tempted by the incremental vacuum feature. Incremental
> vacuum will reduce the database size as content is deleted, but it
> will not reduce fragmentation. In fact, incremental vacuum will
> likely increase fragmentation. Incremental vacuum is just a variation
> on auto_vacuu
Hi,
sqlite does not enforce datatypes. In this, sqlites works differently
from other database engines.
See http://www.sqlite.org/different.html and search for "*Manifest typing"
The key sentence is
*"SQLite thus allows the user to store any value of any datatype into
any column regardless of th
Hello,
I am working on Database not for a long time. From SQLITE Tutorial exam
table :*
->> Why is it possible to change data not defined in the constraint :
Exemple : enter TEXT if the column is INTERGER ??
enter 25 caracters if column is declared VARCHAR(15) ??
I thought i will
I'm not sure if anyone replied further, but: when you use the Web
interface to subscribe to the list:
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-announce
One of the options you have is "Would you like to receive list mail
batc
you can also use ifnull(myvar1,'') = ifnull(myvar2,'')
or something in the same way.
I used it for avoiding creating 2 queries for each cases.
Cheers,
Sylvain
On Wed, Mar 11, 2009 at 4:14 PM, Jim Wilcoxson wrote:
> I used the Solid database for many years, since they came out with
> their Lin
I used the Solid database for many years, since they came out with
their Linux version back in 1998. Initially they had this behavior.
Later they added = NULL so that it worked like IS NULL. My guess is
that, standard or not, this was so utterly confusing to most people
that it was better to be s
Hi Tom,
yes, you are right. It does not matter how you put the NULL in your
query. The bind variable does not change the operator from = to IS.
However, if you do not want to change the SQL text, and know a value
which your field will never have, and do not use an index, then you can
write
---
Thanks for the quick response! Yes, I understand the differences between
querying with IS NULL vs. = NULL. But I had always thought that when using
*parameter binding* a NULL query parameter would be treated like the IS NULL
case when doing the comparison, not the equality case. Hmm, Sounds l
On Wed, Mar 11, 2009 at 9:14 AM, Hynes, Tom wrote:
>> ... yes, this is expected.
>
> Can you explain that a bit more? I certainly would not have expected it.
> Thanks.
sqlite> CREATE TABLE foo (a);
sqlite> INSERT INTO foo VALUES (1);
sqlite> INSERT INTO foo VALUES ('ab');
sqlite> INSERT INTO f
> ... yes, this is expected.
Can you explain that a bit more? I certainly would not have expected it.
Thanks.
Tom
-Original Message-
From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-boun...@sqlite.org]
On Behalf Of Martin Engelschalk
Sent: Wednesday, March 11, 2009 8:59 AM
On Wed, 11 Mar 2009 06:12:37 -0700 (PDT), Derek Developer
wrote:
>I have read and searched but I am not able to
>get the following statement to run:
> SELECT MyID, Zip FROM TableOne d
> LEFT OUTER JOIN DatabseTwo.sdb.TableTwo n
> ON n.MyID=d.MyID WHERE d.Zip > 8 ORDER BY d.Zip
>
>I just ge
This is now all sorted and it was indeed a simple bug in the wrapper.
When parsing out the create table statement it hadn't anticipated the double
quotes surrounding the tables and fields.
I understand that this is in fact the standard/recommended way, although I
don't do it myself and prefer: CREA
Hi Rajesh Nair,
It works perfectly,
Thank you,
Michael
> If you want to use sqlite3_exec function then try this
>
> char *zSQL = sqlite3_mprintf("INSERT INTO probes VALUES(%Q)", temp);
> sqlite3_exec(db, zSQL, 0, 0, 0);
> sqlite3_free(zSQL);
>
> This will format "temp" to hold any special chars
On 12/03/2009 12:12 AM, Derek Developer wrote:
> I have read and searched but I am not able to get the following statement to
> run:
> SELECT MyID, Zip FROM TableOne d LEFT OUTER JOIN DatabseTwo.sdb.TableTwo n ON
> n.MyID=d.MyID WHERE d.Zip > 8 ORDER BY d.Zip
>
> I just get error at "."
>
>
On Wed, Mar 11, 2009 at 8:12 AM, Derek Developer
wrote:
> I have read and searched but I am not able to get the following statement to
> run:
> SELECT MyID, Zip FROM TableOne d LEFT OUTER JOIN DatabseTwo.sdb.TableTwo n ON
> n.MyID=d.MyID WHERE d.Zip > 8 ORDER BY d.Zip
>
> I just get error at
I have read and searched but I am not able to get the following statement to
run:
SELECT MyID, Zip FROM TableOne d LEFT OUTER JOIN DatabseTwo.sdb.TableTwo n ON
n.MyID=d.MyID WHERE d.Zip > 8 ORDER BY d.Zip
I just get error at "."
I tried specifiying the databse name without the file extensio
If you want to use sqlite3_exec function then try this
char *zSQL = sqlite3_mprintf("INSERT INTO probes VALUES(%Q)", temp);
sqlite3_exec(db, zSQL, 0, 0, 0);
sqlite3_free(zSQL);
This will format "temp" to hold any special chars which may generate
some errors.
eg:- temp = " Rajesh's Test " will be
Hi,
yes, this is expected. Note that you use the = - operator in WHERE
maybenullcolumn = @value
and NULL = NULL evaluates to false.
This is SQL standard.
Martin
diego.d...@bentley.com wrote:
> Hello,
>
> In my usage of SQLite, I found a behavior that might be considered a
> bug, but I would lik
Hello,
In my usage of SQLite, I found a behavior that might be considered a
bug, but I would like others' input on it.
Consider the following table with a single row, with one column
containing a null value:
CREATE TABLE MyTable (id integer primary key autoincrement, label
char(255), maybenullco
Hi,
use sqlite3_prepare and sqlite3_bind.
See http://www.sqlite.org/capi3ref.html#sqlite3_prepare
and sqlite3_bind_text under
http://www.sqlite.org/capi3ref.html#sqlite3_bind_blob
const char* szTail=0;
sqlite3_stmt* pVM;
int nRet = sqlite3_prepare(mpDB, "insert into table1 values(?)",
Good Morning,
I would like to write in C the equivalent code for:
insert into table1 values('Hello');
using a variable char temp[20]= "Hello";
instead of the literal Hello
I have used multiple variations of the following, but no luck
char temp[20]= "Hello";
sql = "INSERT INTO pro
I did see that function and I had already tried that but it just gives me
"SQL logic error or missing database". The error code from the step command
is 19 (constraint error). I t almost looks like a different error, but if I
take out the triggers it works.
Thanks
Andy
On Wed, Mar 11, 2009 a
At 03:47am on 2009 March 08, VF did write:
> CREATE UNIQUE INDEX MAP_IDX_$idx ON MAPPINGS_$idx (key, mapping);
> CREATE INDEX KEY_IDX_$idx ON MAPPINGS_$idx(key);
>
> I am trying to do an upsert with the following logic:
>
> UPDATE MAPPINGS_$idx
> SET counter = counter + 1
> , timeModified = CURR
Citando Igor Tandetnik :
> galea...@korg.it wrote:
>> is it possible to use a similar function to get_table but starting by
>> a statement in order to use the bind facilities?
>
> Anything wrong with calling sqlite3_step in a loop?
>
> Igor Tandetnik
>
>
>
> ___
manohar s wrote:
> Hi,
> I am trying to execute "PRAGMA page_size=4096; Vacuum;" on a SQLite DB(Size
> 1.5 GB), On a drive which has 9 GB free space (But my C: has 150 MB free is
> this an issue?). But it is failing with "SQL Error:Database or disk is full"
> error everytime. SQLite version: 3.6.1
41 matches
Mail list logo