[sqlite] anyone know how to use ta-lib api to the sqlite database?

2013-06-19 Thread YAN HONG YE
the ta-lib.org, the ta-lib library could use in EXCEL, I wanna use it in the sqlite database, but I don't know how to write the c or c++ code to load the ta-lib api in sqlite database, anyone know it? ___ sqlite-users mailing list sqlite-users@sqlite.or

[sqlite] Connection between SQLite - Other Databases

2013-06-19 Thread Reddy C. balaji
Hi All, Please let me know the options available to connect to other databases ( Oracle, MSSQL , MySQL etc ) from SQLite. For example, to connect from Oracle to other databases DBLink can be used. In the same way, from MSSQL , Linked Server can be used to connect to other databas

Re: [sqlite] use sqlite to count macd value

2013-06-19 Thread Simon Slavin
On 20 Jun 2013, at 2:04am, YAN HONG YE wrote: > DIFF : EMA(CLOSE,12) - EMA(CLOSE,26); > DEA : EMA(DIFF,9); > MACD : 2*(DIFF-DEA); > > I wanna use sqlite to count macd value, have any idea? You cannot calculate moving average inside SQLite, because table rows do not appear to aggregate functi

[sqlite] use sqlite to count macd value

2013-06-19 Thread YAN HONG YE
DIFF : EMA(CLOSE,12) - EMA(CLOSE,26); DEA  : EMA(DIFF,9); MACD : 2*(DIFF-DEA); I wanna use sqlite to count macd value, have any idea? thank you! ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite

[sqlite] Error with new HTTPS configuration on sqlite.org (missing certificate chain up to CA)

2013-06-19 Thread Oliver Schneider
Hi, using Opera I receive the following error: > Could not connect to remote server > > You tried to access the address https://sqlite.org/lang_attach.html, which is > currently unavailable. Please make sure that the web address (URL) is > correctly spelled and punctuated, then try reloading t

Re: [sqlite] escape quote for csv import

2013-06-19 Thread Steve Martin
Hi > (There is no official CSV standard, and there is no widely supported escaping > mechanism.) Refer to RFC4180 for CSV standard. Steve Martin Technical Lead NEC New Zealand Limited NEC House, Level 6, 40 Taranaki Street, PO Box 1936, Wellington 6140, New Zealand T: 043816291 M: 029381629

Re: [sqlite] escape quote for csv import

2013-06-19 Thread j . merrill
The fact that there's no "official CSV standard" doesn't mean that there isn't "common practice" that SQLite should support (but I can't say that I know that it does; it should be easy to change if it doesn't). The "common practice" is to double each embedded double-quote. "abc","the char in

Re: [sqlite] General question on 'style' Simon/Stephen.

2013-06-19 Thread Rob Willett
Hi, I wasn't overaly bothered about performance, since my backend jobs take hours to run and processing TB's of data, the overhead of opening and closing a few hundred database connections in the grand scheme of things is pretty low. It was a general style and usage question. I'm a C hacker by

Re: [sqlite] General question on 'style' Simon/Stephen.

2013-06-19 Thread RSmith
Actually, having benched this specific thing before, I can tell you that there is a performance penalty opeining and closing DBs (as opposed to just keeping a connection open) - but this is not news, what might be news is that the performance penalty is much much smaller than I anticipated and in

Re: [sqlite] Use more than one database in one application

2013-06-19 Thread Gianni Sassanelli
If you open SQLite db by SQLLite plugin in Android, you must look in plugin source to found your problem. The bug was there because there is always 1 db opened for time end db opened is always the last opened if you try sqlite3_open16 (“db1.db”, db_1); // open first sqlite3_open16 (“db2.db”, db_

Re: [sqlite] First Day of Week Inconsistency

2013-06-19 Thread Michael Black
Oops...forgot to add what you want. %U The week number of the current year as a decimal number, range 00 to 53, starting with the first Sunday as the first day of week 01. See also %V and %W. And this one: %V The ISO 8601:1988 week number of t

Re: [sqlite] First Day of Week Inconsistency

2013-06-19 Thread Simon Slavin
On 19 Jun 2013, at 5:20pm, Denis Burke wrote: > It seems to me these useful functions are inconsistent. They are inconsistent with one-another. But both functions are implemented to the standards, correctly as far as lots of POSIX-based computing is done. It’s annoying but it’s correct. So

Re: [sqlite] First Day of Week Inconsistency

2013-06-19 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 19/06/13 09:20, Denis Burke wrote: > Is it possible to modify %W to treat Sunday as the first day of the > week? Traditionally strftime %W uses Monday to start each week while %U uses Sunday. It looks like SQLite doesn't implement the latter. Rog

Re: [sqlite] First Day of Week Inconsistency

2013-06-19 Thread Michael Black
Those are unrelated questions.day of week has nothing to with the start of a week. >From the standard strftime man page which has been around for decades. %w The day of the week as a decimal, range 0 to 6, Sunday being 0. See also %u. %W The week numbe

[sqlite] First Day of Week Inconsistency

2013-06-19 Thread Denis Burke
The built-in function strftime properly (imho) responds to the '%w' command for day of week with Sunday as day 0. e.g. - strftime ('%w','2013-06-19') -> 3 But the built-in function for returning week of the year treats weeks as though they begin on Monday, not Sunday: e.g. strftime ('%W','2013-

Re: [sqlite] General question on 'style' Simon/Stephen.

2013-06-19 Thread Rob Willett
Stephen, Simon, I'm not worried about the CPU load at all, it was purely a question of style. Stephan has talked about keeping the connections open for the lifetime of a desktop connection, Simon has talked about closing and opening connections many, many times during the course of a transactio

Re: [sqlite] General question on 'style'

2013-06-19 Thread Simon Slavin
On 19 Jun 2013, at 3:15pm, Rob Willett wrote: > Now to the hub (excuse the really bad pun) of my questions, within my service > side application, I'm finding that I'm constantly opening and closing the > same SQLite database, inserting data, reading data, updating date over many > hours. The

Re: [sqlite] General question on 'style'

2013-06-19 Thread Stephen Chrzanowski
IMO, depends on the type of process wanting to make a connection. Anything web service wise is typically stateless, which means any time a new request is made, you have to re-open a new connection. You can probably get away with using server side variables to handle the connections, as I did in A

[sqlite] General question on 'style'

2013-06-19 Thread Rob Willett
Hi, My first question as a lurker and read of these groups. Hopefully it's not too stupid :) I've been working through using SQLite on my Mac and have a question on style and the way to use SQLite databases. My application has two parts, a client/PHP side to collect requests from a user and a

Re: [sqlite] How to select from a temp table with same name as a main table.

2013-06-19 Thread Clemens Ladisch
Igor Tandetnik wrote: > On 6/19/2013 8:18 AM, Clemens Ladisch wrote: >> says: >> | If two or more tables in different databases have the same name and >> | the database-name prefix is not used on a table reference, then the >> | table chosen is the one in th

Re: [sqlite] How to select from a temp table with same name as a main table.

2013-06-19 Thread Igor Tandetnik
On 6/19/2013 8:18 AM, Clemens Ladisch wrote: says: | If two or more tables in different databases have the same name and | the database-name prefix is not used on a table reference, then the | table chosen is the one in the database that was least recently

Re: [sqlite] How to interrupt a long running update without roll back?

2013-06-19 Thread Ryan Johnson
On 19/06/2013 1:41 AM, jhnlmn wrote: Thank you for your response Simon Slavin writes: UPDATE T SET C1 = calculation(C2) WHERE C1 IS NULL AND rowid < 1 This is the best solution when the table is freshly created and max(rowid) == number of rows. But after many deletes and inserts many rowi

Re: [sqlite] How to select from a temp table with same name as a main table.

2013-06-19 Thread Clemens Ladisch
dochsm wrote: > I would have thought having no database prefix would default to the > main says: | If two or more tables in different databases have the same name and | the database-name prefix is not used on a table reference, then the | table chosen is th

Re: [sqlite] How to select from a temp table with same name as a main table.

2013-06-19 Thread dochsm
That brilliant. It is as I thought. Odd behaviour though. I would have thought having no database prefix would default to the main, after all I don't put the prefix there usually and if you try to create two tables in the same db you get an error (obviously). To be on the safe side I've re-written

Re: [sqlite] How to interrupt a long running update without roll back?

2013-06-19 Thread Simon Slavin
On 19 Jun 2013, at 6:41am, jhnlmn wrote: > Simon Slavin writes: > >> Do you have an index on T(C1) ? >> That should dramatically reduce the search time. > > I tried adding index. > It caused slow down of the original insert of records to the table by about > 25%, which is unacceptable to me

Re: [sqlite] How do I show pragma settings

2013-06-19 Thread Hick Gunter
There is no documented way to show the value of this pragma (which is only used to debug SQLite anyway). Other (settable) pragmas have query form (PRAGMA xxx;) and an "update" form (PRAGM xxx=value;). -Ursprüngliche Nachricht- Von: sqlitekyounoii [mailto:sqlitekyoun...@yahoo.co.jp] Gese

[sqlite] How do I show pragma settings

2013-06-19 Thread sqlitekyounoii
I want to show "pragma parser_trace" settings. How do I show pragma settings? ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users