Wikipedia also disagrees with the 24. Nov of 4714 B.C. as start of
julian days...
http://en.wikipedia.org/wiki/Julian_day
(Footnote from that page..)
^ This equals November 24, 4714 BC in the proleptic Gregorian calendar.
--
- Original Message -
From: "Guy Hachlili" <[EMAIL PROTECTED]>
To:
Sent: Friday, February 02, 2007 10:13 AM
Subject: RE: [sqlite] How do I know sqlite_get_table is finished
In any case, I've worked a bit on the function, and here's the result:
Thanks alot. It's much appreciated.
- T
The function ArrayToSheet has nil to do with SQLite and I left that out.
Ah, but that's where you access the variant array. That can be tricksy. Do
you always access that variant array (arr) in the range (0 To NumRecords, 0
To NumColumns - 1) where the row arr(0, *) holds the column names, and
Wesley wrote:
As an example: in an instant messenger a new text message arrives. The
application puts it into the message log. The chat window automatically
updates with the new text. The statistics window about total # of
messages updates. Possibly other things happen. The point is I don't
It looks all as it should work and it compiles with the same number of
warnings, but I get a bad dll calling convention in VB with the extra
integer argument iFields.
You've changed the signature of the method you're calling, and it looks like
you changed it correctly in the VB declaration. May
Hi, I'm querying a table by writing the query in sqlite3_exec with a
callback function that does some operation on the resulting row.
Everything is fine when the table has even one row, but when it is
empty, my program halts with "segmentation fault". I can add a dummy row
to the table to prevent
Hello all,
I'd like to perform an update to a row if it exists (uniquely identified by
3 text columns), otherwise insert a new row with the right data. INSERT OR
REPLACE looks good, but it generates a new primary key each time there is a
conflict. If the row exists, I need to keep the original
Am I able to perform a transaction where I execute a query with a
begin..insert..end and commit? Would that even be faster?
Yep, that's the way to go.
http://www.sqlite.org/cvstrac/wiki?p=PerformanceConsiderations
See
Transactions and performance
---
The 3.3.17 ZIP file seems to only contain 2 source files, instead of the
full SQLite source. Is this on purpose?
It is the full source. See
http://www.sqlite.org/cvstrac/wiki?p=TheAmalgamation
and a big ol' thread at
http://www.nabble.com/May-I-ask-why-the-source-distribution-mechanism-was-chang
lsewhere too..
- Trey
- Original Message -
From: "B V, Phanisekhar" <[EMAIL PROTECTED]>
To:
Sent: Tuesday, May 08, 2007 10:59 AM
Subject: RE: [sqlite] INSERT OR REPLACE without new rowid
Hi Trey,
Even I was looking for something like this. But I don't think SQL
Works for me straight out of the box on Windows XP.
That program does have the capability, but may not be implemented that way
on Windows. Why not make the change yourself?
A.J.Millan wrote:
As a suggestion, and even in the risk to abuse of Mr Hipp's patience.
Would
it be possible to inclu
Inside string literals, escape single quotes with 2 single quotes
'test 'test' test' ==> 'test ''test'' test'
When I try to insert text containg single quotes via php it gives me
syntax
error:
...
// so query looks like:
INSERT INTO version (date,active,category,entry) VALUES ('2007-05-
Included functions:
http://www.sqlite.org/lang_expr.html
See the section "Core Functions" near the bottom of the page for the builtin
functions.
To add more:
http://www.sqlite.org/contrib
extension-functions.tgz for details on adding functions like ceil.
- TM
- Original Message -
Fr
I see that it is a variant of type VT_BSTR containing
"2345678.9123" (or whatever), and I have to use strtod() to convert it
to the number I want. Is there a way to write the query to ensure that
it will give me a number instead of a string?
The type selection is done in your ODBC wrapper, and
I checked not implemented features list of sqlite and found nothing
about "update ... from".
There's no "FROM" on http://www.sqlite.org/lang_update.html, so that's a
hint that it's not supported. All the same, maybe this should be added to
http://www.sqlite.org/omitted.html
update table1 se
Here's what I tried, which didn't work...
select
name,
substr(name,1,length(name)-3) as zone,
substr(name,length(name)-2,2) as location,
max(thick) - min(thick) as diff from plypoint
where diff > 0.0005
group by zone,location
That causes a "misuse of aggregate" error.
select
name,
substr(name,
> I have a fairly large table (10million rows) with a simple INTEGER
> PRIMARY KEY AUTOINCREMENT field.
>
> Executing 'SELECT max(rowid) FROM MyTable' is very fast, as is
> 'SELECT min(rowid) FROM MyTable'.
>
> However, 'SELECT max(rowid) - min(rowid) FROM MyTable' is slow
> (apparently accessi
I want to insert the transactions data (product_id, buy, sell, desc) into
the sale_products table. But I want a mechanism whereby if I enter the
product_id, then the buy, sell, desc columns are auto entered (copied)
from their corresponding row in the products table.
Given:
CREATE TABLE p
I rather thought about retrieving and storing milliseconds in SQL. I
mean, a SQL data type which is able to store milliseconds and a SQL
function to return the current timestamp including milliseconds. I had
no luck with CURRENT_TIMESTAMP for instance.
There is no true SQLite DATE data type. It'
When using the command line interface sqlite3, a couple of times I have
forgotten to use the "." before a command. After that I get a "...>"
prompt that I can't seem to escape from and accepts no commands? My only
choice is to shut down that terminal and start a new one..
There must be an e
I'm creating some indices, and want to know if it's going to help or hurt me
(or be totally irrelevant because of optimization) to include the primary key
at the end of the index. All of my tables (in question) have an INTEGER PRIMARY
KEY AUTOINCREMENT field, and I have several textual descripto
I want to have queries that will match dates but not care about times.
The date might be today, anything within the last week, month, year,
or a range of dates. I'm using Python's datetime function, so the
dates enter the database in this format 2007-09-01 12:00:02.
So far, < or > queries seem t
At the moment I open 1 connection to the SQL Serv.. at the moment of
login and I keep it open until the user exit the program.
Can I do the same with SQLite, or do you suggest to open and close the
connection every time I need it? Will I lose Performance?
As I understand it, that's the way t
At the moment I open 1 connection to the SQL Serv.. at the moment of
login and I keep it open until the user exit the program.
Can I do the same with SQLite, or do you suggest to open and close the
connection every time I need it? Will I lose Performance?
As I understand it, that's the wa
I add records to database tables. Then when i delete them the database do
not
reduce size. I add BLOB elements. Do you know what can be the problem?
Thanks
http://www.sqlite.org/lang_vacuum.html
-
To unsubscribe,
How do I filter out records that contain WHITE SPACE in a field or
have this field empty?
For example:
select * from mytable
where fld <> "" and fld LIKE .
Do you mean "contain ONLY white space"? Are you after this?
select * from mytable
where trim(fld) <> ""
---
INSERT INTO invoice_items
(item_id,invoice_id,product_id,product_name,sku,description,quantity,price,cost,taxable,taxable2,format_price,format_total_price)
VALUES (NULL,899,1001975,'HD0001 - ASH - YL','','HOUSE
DIVIDED',1,800,450,'f','f','$8.00','$8.00')
Does this work?
INSERT INTO invoice_item
Can you please tell me what
other databases do with this:
CREATE TABLE t1(a,b,c);
INSERT INTO t1 VALUES(1,2,4);
SELECT a+b AS c FROM t1 WHERE c==4;
SQL Server returns a 3.
ORACLE 9 returns a 3.
-
To unsubscri
3.6.0 in the next release? Or can we call the change
a "bug fix" and number the next release 3.5.4?
I guess I'm in the minority, but I'd find a change in the meaning of
my queries surprising in a bug fix release. That sounds like a 3.6 to
me.
You may be in the minority, but you're not a
UPDATE listings SET buyer = 'Price' WHERE listnum = 12345
Double quotes are for column names.
Walt wrote:
> I have a table 'listings' with fields 'listnum', 'price' and 'buyer' etc.
>
> executing the following sql
>
> UPDATE listings SET buyer = "Price" WHERE listnum = 12345
>
> results in the '
Is this what you're after?
create table LSOpenJobs (PSubClass);
insert into lsopenjobs values ('DOC-Trans');
insert into lsopenjobs values ('DTP');
insert into lsopenjobs values ('PM');
insert into lsopenjobs values ('Post-Proc');
insert into lsopenjobs values ('Pre-Proc');
select * from lsopenjo
create table t1 (rpsIndex INTEGER);
create table t2 (rpsIndex INTEGER);
create table t3 (rpsIndex INTEGER);
insert into t1 values (1);
insert into t1 values (1);
insert into t1 values (2);
insert into t2 values (1);
insert into t2 values (2);
insert into t2 values (3);
insert into t3 values (3);
i
You are not guaranteed any particular order unless you use ORDER BY,
even between two runs of the same SQL statement.
Roland Romvary wrote:
> Hi!
>
> Can I take it for sure that the order of the rows returned by 2 queries are
> the same?
> The only difference between the queries is that the selec
Two pipes
||
Jason Salas wrote:
> I'm new to SQLite, coming over from SQL Server. I often do string
> concatenation like so:
>
> lastName + ', ' + firstName as [name] from myTable
>
> But it tries to run a math computation and returns '0.0' for each
> field. I've tried some other concat opera
Store it in '-mm-dd' format, or use the julian date that's suggested at:
http://www.sqlite.org/cvstrac/wiki?p=DateAndTimeFunctions
Yong Zhao wrote:
> It seems that sqlite3 does not support DATETIME data type.
>
> If I have the following data in table t1, how do I select people who is
> older
From http://www.sqlite.org/formatchng.html
"Version 3.0.0 is a major upgrade for SQLite that incorporates support for
UTF-16, BLOBs, and a more compact encoding that results in database files
that are typically 25% to 50% smaller. The new file format is very different
and is completely incompat
I have just one question.
What exactly does this function do:
Private Declare Function sqlite3_changes _
Lib "SQLite3VB.dll" (ByVal DB_Handle As Long) As Long
It looks it will always give one, unless you have just created a database
and done nil with it. Is this how it is?
It returns the num
I cannot find a PRAGMA for turning column names on/off either. You may be
thinking of ".headers on/off" in the SQLite shell..
I don't think there's a way to turn this off, except rewriting the code for
sqlite_get_table (which, thankfully, he's provided). Maybe to include a 4th
parameter that w
Actually, my query is something like
SELECT ... FROM ... WHERE `pid` = (SELECT `id` FROM ...);
if i put that group by... will it group all rows, or only those with
the same pid?
Use a subquery
SELECT price, sum(count) FROM (
-- your original query here
SELECT price, count FROM ... WHERE `
select * from t order by rowid desc limit 1;
Thanks,
Trey Mack
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Aravinda babu
Sent: Wednesday, September 17, 2008 2:15 AM
To: sqlite-users@sqlite.org
Subject: [sqlite] Getting the last row
Hi all,
Is there
40 matches
Mail list logo