Re: [sqlite] fts3b-4.9 fails - FTS3 docid updates now possible with latest version?

2009-12-03 Thread Ralf Junker
On 02.12.2009 20:00, Dan Kennedy wrote: > On Dec 2, 2009, at 3:07 PM, Ralf Junker wrote: > >> * Is it now intentionally possible to update FTS3 DOCIDs? > > It is. The failing sqlite test case has been replaced. Thanks you, Dan! I had alre

Re: [sqlite] Error message from sqlite3_tokenizer_module.xCreate?

2009-12-03 Thread Ralf Junker
On 01.12.2009 09:01, Dan Kennedy wrote: >> Monday 30 of November 2009 12:29:10 Ralf Junker napisał(a): >> I am passing various arguments to sqlite3_tokenizer_module.xCreate. >> In case they are invalid, I would like to return an explaining >> error message in additio

[sqlite] fts3b-4.9 fails - FTS3 docid updates now possible with latest version?

2009-12-02 Thread Ralf Junker
With the latest FTS3 changes, fts3b-4.9 no longer passes. This short SQL emulates the test: DROP TABLE IF EXISTS t4; CREATE VIRTUAL TABLE t4 USING fts3(c); INSERT INTO t4 (docid, c) VALUES (12, 'still testing'); UPDATE t4 SET docid = 14 WHERE docid = 12; Note that SQLite 3.6.20

Re: [sqlite] sqlite3ExprCodeIN() problems with SQLITE_OMIT_SUBQUERY

2009-12-01 Thread Ralf Junker
On 01.12.2009 18:35, Jay A. Kreibich wrote: > Important Note: The SQLITE_OMIT_* compile-time options are > unsupported. Oops! Thanks for focusing my eyes - they tend to skip introductions and move right to the details. Now having that read, let me point out that in spite of the statement the

Re: [sqlite] sqlite3ExprCodeIN() problems with SQLITE_OMIT_SUBQUERY

2009-12-01 Thread Ralf Junker
On 01.12.2009 18:05, D. Richard Hipp wrote: > The key point to bare in mind here is that SQLITE_OMIT_SUBQUERY is > not a supported compile-time option. None of the major users of > SQLite make use of SQLITE_OMIT_SUBQUERY. We do not test it. And it > appears that it is broken in the current

[sqlite] sqlite3ExprCodeIN() problems with SQLITE_OMIT_SUBQUERY

2009-12-01 Thread Ralf Junker
Compiling with SQLITE_OMIT_SUBQUERY, sqlite3ExprCodeIN() is compiled out but at the same time still required at other places in expr.c. As such, expr.c does not link well with SQLITE_OMIT_SUBQUERY defined. After I wrapped the remaining references to sqlite3ExprCodeIN() by #ifndef

[sqlite] Problem with #include in fts3Int.h

2009-12-01 Thread Ralf Junker
I have a compilation problem with line 22 in fts3Int.h: #include According to http://gcc.gnu.org/onlinedocs/cpp/Include-Syntax.html, includes are used for system header files, which sqlite3.h is not IMHO. I tried to replace with #include "sqlite3.h" but this resulted in a number of

Re: [sqlite] Error message from sqlite3_tokenizer_module.xCreate?

2009-12-01 Thread Ralf Junker
On 01.12.2009 09:01, Dan Kennedy wrote: > I don't think it is possible at the moment. Unfortunately. Thanks for the clarification, Dan! I observe that you are currently writing the "official" FTS3 documentation in preparation for the next release of SQLite. Maybe you want to make tokenizer

Re: [sqlite] Error message from sqlite3_tokenizer_module.xCreate?

2009-11-30 Thread Ralf Junker
On 30.11.2009 20:33, Grzegorz Wierzchowski wrote: > Monday 30 of November 2009 12:29:10 Ralf Junker napisał(a): >> I am passing various arguments to sqlite3_tokenizer_module.xCreate. In case >> they are invalid, I would like to return an explaining error message in >> additi

[sqlite] Error message from sqlite3_tokenizer_module.xCreate?

2009-11-30 Thread Ralf Junker
I am passing various arguments to sqlite3_tokenizer_module.xCreate. In case they are invalid, I would like to return an explaining error message in addition to SQLITE_ERROR. I did not find a way to do this. Is it at all possible? Thanks, Ralf ___

[sqlite] Error message from sqlite3_tokenizer_module.xCreate?

2009-11-30 Thread Ralf Junker
I am passing various arguments to sqlite3_tokenizer_module.xCreate. In case they are invalid, I would like to return an explaining error message in addition to SQLITE_ERROR. I did not find a way to do this. Is it at all possible? Thanks, Ralf ___

Re: [sqlite] Bug report: Memory reused after freed

2009-09-29 Thread Ralf Junker
At 14:04 29.09.2009, Dan Kennedy wrote: >On Sep 29, 2009, at 4:30 PM, Ralf Junker wrote: > >> My memory manager reports that the SQL below results in memory being >> reused after it has already been freed when it is RUN FOR A SECOND >> TIME on the same databas

Re: [sqlite] Bug report: Memory reused after freed

2009-09-29 Thread Ralf Junker
At 14:04 29.09.2009, Dan Kennedy wrote: >On Sep 29, 2009, at 4:30 PM, Ralf Junker wrote: > >> My memory manager reports that the SQL below results in memory being >> reused after it has already been freed when it is RUN FOR A SECOND >> TIME on the same databas

[sqlite] Bug report: Memory reused after freed

2009-09-29 Thread Ralf Junker
My memory manager reports that the SQL below results in memory being reused after it has already been freed when it is RUN FOR A SECOND TIME on the same database connection. Psydocode (I do not run C): sqlite3_initialize; sqlite3_open(DB_FILE_NAME, ); sqlite3_exec(DB, SQL, NULL, NULL,

Re: [sqlite] GROUPY BY alias backward incompatibility

2009-05-30 Thread Ralf Junker
At 15:37 28.05.2009, D. Richard Hipp wrote: >Have you tried these two queries on other SQL database engines besides >SQLite? What do PostgreSQL and MySQL make of them? I could now run the queries on Oracle Database 10g Express Edition Release 10.2.0.1.0. Prepare the table: create table t

Re: [sqlite] GROUPY BY alias backward incompatibility

2009-05-28 Thread Ralf Junker
At 15:37 28.05.2009, D. Richard Hipp wrote: >Have you tried these two queries on other SQL database engines besides >SQLite? What do PostgreSQL and MySQL make of them? MySQL (5.0.21) reports no erros on either of both queries: select (select count(*) from t t_inner group by

Re: [sqlite] GROUPY BY alias backward incompatibility

2009-05-28 Thread Ralf Junker
At 13:27 28.05.2009, D. Richard Hipp wrote: >On May 28, 2009, at 7:01 AM, Ralf Junker wrote: > >> Hello! >> >> Up to version 3.5.3, SQLite would happily execute this SQL without >> complaints: >> >> drop table if exists t; >> >> create t

Re: [sqlite] GROUPY BY alias backward incompatibility

2009-05-28 Thread Ralf Junker
At 13:27 28.05.2009, D. Richard Hipp wrote: >On May 28, 2009, at 7:01 AM, Ralf Junker wrote: > >> Hello! >> >> Up to version 3.5.3, SQLite would happily execute this SQL without >> complaints: >> >> drop table if exists t; >> >> create t

[sqlite] GROUPY BY alias backward incompatibility

2009-05-28 Thread Ralf Junker
Hello! Up to version 3.5.3, SQLite would happily execute this SQL without complaints: drop table if exists t; create table t (c); select (select count() from t t_inner group by t_outer.c) from t t_outer; This behaviour changed in version 3.5.4. From then on, SQLite issues an

Re: [sqlite] Table-Alias Confusion or Bug?

2009-05-27 Thread Ralf Junker
At 17:33 27.05.2009, D. Richard Hipp wrote: >On May 27, 2009, at 11:26 AM, Ralf Junker wrote: > >> Hello! >> >> Given this SQL: >> >> drop table if exists t; >> >> create table t (c); >> >> select * >>from t as ta >

[sqlite] Table-Alias Confusion or Bug?

2009-05-27 Thread Ralf Junker
Hello! Given this SQL: drop table if exists t; create table t (c); select * from t as ta where t.c = ta.c; SQLite3 chokes with the following error: SQL error near line 5: no such column: t.c Question: Is this the expected behaviour? I know that the where clause does not

Re: [sqlite] group_concat bug

2009-05-07 Thread Ralf Junker
Confirmed and created ticket http://www.sqlite.org/cvstrac/tktview?tn=3841. Ralf At 03:10 07.05.2009, Steve Bauer wrote: >The following example demonstrates what seems to be a bug in group_concat. >With the latest version of CVS: > >CREATE TABLE example (id INTEGER, x TEXT); >CREATE TABLE

Re: [sqlite] Strange SAVEPOINT behaviour with locking_mode=exclusive

2009-04-20 Thread Ralf Junker
At 15:37 20.04.2009, D. Richard Hipp wrote: >Ticket #3811 has been addressed by enhancing the documentation to >explain that journal_mode changes are only guaranteed to work if they >occur prior to the first transaction. Whether or not a journal_mode >change works after the start of the

[sqlite] Strange SAVEPOINT behaviour with locking_mode=exclusive

2009-04-17 Thread Ralf Junker
I experience some strange behaviour with SAVEPOINT in combination with locking_mode=exclusive. Below is a script which I assembled from savepoint.text 13.1 to 13.4. Those tests run OK in normal locking mode, but fail in exclusive locking more. To reproduce, run the script below on a NEW and

Re: [sqlite] Feature request: Report constraint name(s) in error message

2009-03-09 Thread Ralf Junker
Roger Binns wrote: >> when a named constraint is violated, the name of the constraint which >> actually failed is not included in the error message. > >There has been a ticket about this for over 3 years, and also includes a >patch to fix it: > > http://www.sqlite.org/cvstrac/tktview?tn=1648

Re: [sqlite] tool to browse a sqlite database

2009-03-08 Thread Ralf Junker
RB Smissaert wrote: >What SQLite version produced the file World.db3? I am not 100% sure about the exact SQLite version which I used to create the original World.db3, but I am VACUUMing it regularly to bring it up to date with recent versions. So I expect it should be some version after 3.6.8.

[sqlite] Feature request: Report constraint name(s) in error message

2009-03-08 Thread Ralf Junker
Hi, when a named constraint is violated, the name of the constraint which actually failed is not included in the error message. Example 1: create table con ( a text constraint must_not_be_null not null); insert into con values (null); Returns error "con.a may not be null". Example

Re: [sqlite] tool to browse a sqlite database

2009-03-08 Thread Ralf Junker
BareFeet wrote: >See a comparison of several GUI SQLite tools here: >http://www.tandb.com.au/sqlite/compare/?ml SQLiteSpy is missing from the list. It is available from http://www.yunqa.de SQLiteSpy is a Unicode SQLite3 database browser GUI for Win32. Features include: * Database at a

Re: [sqlite] Impossible to declare field type BIGINT PRIMARY KEY

2008-12-15 Thread Ralf Junker
Markus Hoenicka wrote: >If there's a way to find out at runtime that a column has been defined as >INTEGER PRIMARY KEY instead of as INTEGER, all is well and I'll be able to fix >the sqlite driver accordingly. pragma table_info(table); In SQLite, this SQL returns all columns defined for

Re: [sqlite] FTS 3 Crash in 3.6.5

2008-11-13 Thread Ralf Junker
Shawn Wilsher wrote: >I seem to have found a crash that is 100% reproducible in SQLite 3.6.5. I'm >managed to make a reduced test case in a C file that can be found here: >http://files.shawnwilsher.com/2008/11/12/test.c I could reproduce the problem and opened this ticket to make sure it does

Re: [sqlite] memsys3 vs memsys5

2008-09-09 Thread Ralf Junker
>> Is there any >> reliable method to determine the minimum page-cache allocation size >> needed for a given page_size? >> > >sqlite3_status(SQLITE_STATUS_PAGECACHE_SIZE, ...) Unfortunately, there is extra overhead involved which is not handled by the page cache but is allocated by malloc() if

Re: [sqlite] rtree woes with SQLITE_OMMIT_...

2008-07-19 Thread Ralf Junker
>> I am running the rtree module against an SQLite build which has >> lots of functionality SQLITE_OMIT_...ed. > >Can you be more specific? Exactly which SQLITE_OMIT symbols >are defined? Sure. Here is the list: SQLITE_OMIT_ALTERTABLE SQLITE_OMIT_ANALYZE SQLITE_OMIT_ATTACH

Re: [sqlite] problem building reduced-size sqlite

2008-07-18 Thread Ralf Junker
Steve Friedman wrote: >When trying to build sqlite (latest cvs update) with the following: > >../sqlite-latest/configure --disable-threadsafe --enable-tempstore=always \ > --disable-tcl --enable-extensions \ > CFLAGS="-g -O3 -DSQLITE_ENABLE_RTREE=1 \ > -DTEMP_STORE=2

[sqlite] rtree woes with SQLITE_OMMIT_...

2008-07-18 Thread Ralf Junker
I am running the rtree module against an SQLite build which has lots of functionality SQLITE_OMIT_...ed. Surprisingly, I receive strange errors like SQLITE_NOMEM for simple statements like CREATE VIRTUAL TABLE t6 USING rtree(ii, x1, x2); or SELECT ii FROM t6 WHERE x1>2; Question: Does

Re: [sqlite] Follow-up: changed default ordering of SELECT queries in 3.5.9?

2008-05-30 Thread Ralf Junker
Hello Jens Miltner, >However, I'd still like to know whether the new behavior of returning >the DISTINCT results in 'arbitrary' order is expected. Unless ORDER BY is specified, the result of any SELECT is by definition undefined. This undefined sort order has changed between previous versions

Re: [sqlite] SQLite allows "RowID" to be the name of a column

2008-05-22 Thread Ralf Junker
Darren Duncan wrote: >Ralf Junker wrote: > >>Can you suggest an alternative to a single reserved name to represent the >>column which uniquely identifies a database record under any and all >>circumstances? > >Yes, change the interface to RowID into a routine ca

Re: [sqlite] SQLite allows "RowID" to be the name of a column

2008-05-21 Thread Ralf Junker
Darren Duncan wrote: >I think the real problem here is that SQL allows you to have non-distinct >rows in a table, when all rows should be distinct. SQLite's implicit "RowID" does not allow non-distinct values (except for NULL, but this is documented behavior and only maintained for backwards

Re: [sqlite] SQLite allows "RowID" to be the name of a column

2008-05-21 Thread Ralf Junker
Federico Granata wrote: >have you seen here http://www.sqlite.org/autoinc.html ? Yes, I did. This documentation actually made me realize that the problem is not an implementation flaw but a design error, IMO. See my other answer in this thread for more rationale. Ralf

Re: [sqlite] SQLite allows "RowID" to be the name of a column

2008-05-21 Thread Ralf Junker
Bradley A. Town wrote: >Ralf Junker wrote: > >> This alerts me to a potential danger for SQLite managers which must rely on >> some means to retrieve THE RowID which uniquely identifies a record for >> in-grid table editing. If the "RowID" name can be hijac

Re: [sqlite] Ticket 3128: DISTINCT -> GROUP BY can lead to performance degradation

2008-05-20 Thread Ralf Junker
>> This should NOT happen as SQLite usually rejects duplicate rowids with a >constraint error. > >For this table, the badly-named column "RowID" is actually a text field >that's allowed to be null, not a primary key. > >-- Describe NDXPARAMVALUES_LOCALIZEDSTRING >CREATE TABLE

Re: [sqlite] Ticket 3128: DISTINCT -> GROUP BY can lead to performance degradation

2008-05-20 Thread Ralf Junker
Correcting myself: This should NOT happen as SQLite usually rejects duplicate rowids with a constraint error. >This should happen as SQLite usually rejects duplicate rowids with a >constraint error. ___ sqlite-users mailing list

Re: [sqlite] Ticket 3128: DISTINCT -> GROUP BY can lead to performance degradation

2008-05-20 Thread Ralf Junker
I looked at the database attached to the ticked and noticed that the table contains NULL rowids as well duplicate rowids. This should happen as SQLite usually rejects duplicate rowids with a constraint error. When I run this query: select rowid, count() from ndxparamvalues_localizedstring

Re: [sqlite] sqlite3_transfer_bindings obsolete?

2008-05-19 Thread Ralf Junker
>> Drat. It doesn't look like there's a way to see what's already been >> bound to a statement either, correct? See this thread for a previous disuccsion of the problem: http://www.mail-archive.com/sqlite-users@sqlite.org/msg28610.html Ralf ___

Re: [sqlite] PRAGMA journal_mode not implemented?

2008-05-07 Thread Ralf Junker
>In PERSIST mode, you have two files associated with your database >instead of one. Whenever you move, copy, or rename the database file >you *must* also move, copy or rename the journal file to prevent >database corruption. > >The persistent journal file uses disk space that might

Re: [sqlite] FTS search negative term syntax

2008-05-01 Thread Ralf Junker
>Fair warning, though: It's not entirely clear that the fts search >syntax should aim to hew too closely to consumer-oriented search >syntax. Interesting point, too. Up to now, I always perceived the FTS search syntax to be very much consumer-oriented. It it just too similar to major search

[sqlite] FTS search negative term syntax

2008-04-30 Thread Ralf Junker
Hello, I have a small concern about the FTS negative term search syntax. Currently, all terms following any minus sign ("-") are excluded from the search. This is a very welcome feature, but consider searching for these hyphenated words: Coca-Cola -> FTS finds Coca, but never Cola

Re: [sqlite] View bindings for a statement

2008-04-26 Thread Ralf Junker
Cole Tuininga wrote: >The question is, is there an easy way to extract the actual query >(with the bound variable set) from the statement handle? This topic has already been discussed in length some time ago: http://www.mail-archive.com/sqlite-users@sqlite.org/msg28610.html It would be

Re: [sqlite] How to set memory usage as high as possible -- but not too high?

2008-04-24 Thread Ralf Junker
Jay A. Kreibich wrote: >> >Are you using a 32 bit or 64 bit process. >> >> 32, but it does not matter to the problem. > > When you give examples like "PRAGMA cache_size = 1000;", or 10M > pages which would take something on the order of 15 GB of memory to > service with the default 1K

Re: [sqlite] How to retrieve number of cached pages in memory?

2008-04-23 Thread Ralf Junker
> See the "Pager" data structure and associated variables and functions > in "sqlite-3.5.x/src/pager.c". OK, it seems that the number I am interested in is stored as part of the Pager struct: int nPage; /* Total number of in-memory pages */ Now I just have to figure out

[sqlite] How to retrieve number of cached pages in memory?

2008-04-22 Thread Ralf Junker
I need to retrieve the number of pages a SQLite database connection has currently allocated in memory. The documentation unfortunately turned up no results. I know about "PRAGMA cache_size", but this returns the maximum number of pages possibly allowed in the cache, not the actual number of

Re: [sqlite] blob api

2008-04-22 Thread Ralf Junker
>> I'm using the sqlite3_blob_* api to write a larger text stream >> incrementally. Works a charm, but is there a way to >> change the datatype of the blob to text afterwards ? I'd like to see >> the text easily in f.i. SQLiteSpy. > >Perhaps: SELECT CAST(b AS TEXT) FROM table Yes, this

Re: [sqlite] blob api

2008-04-22 Thread Ralf Junker
>Ok, I was kinda hoping for a more "permanent" solution such as: Did you consider creating a view? >int sqlite3_cast_column_type(sqlite3* db, const char* zDBname, const char* >zTable, const char* zColumn, int newColumnType); > >that would cast the column into the desired type, returning

Re: [sqlite] How to set memory usage as high as possible -- but not too high?

2008-04-14 Thread Ralf Junker
Dan, many thanks for the quick response and detailed answers. However, a question or two still puzzle me. >> * OPTION 1: PRAGMA cache_size = 1000; >> >> Advantage: SQLite will use ample memory, but no more than that. >> >> Disadvantage: Difficulty to establish exact memory requirements in

Re: [sqlite] How to set memory usage as high as possible -- but not too high?

2008-04-14 Thread Ralf Junker
Roger Binns wrote: >Are you using a 32 bit or 64 bit process. 32, but it does not matter to the problem. >Also is there a requirement to create the database in the filesystem? Yes. >If not you could ensure your swap is sufficiently large (I use a mininmum of >16GB on my machines :-) and

[sqlite] How to set memory usage as high as possible -- but not too high?

2008-04-13 Thread Ralf Junker
I need to create a huge database (about 6 GB, more than 6 mio records, blobs, and FTS text) in as little time as possible. Since memory is the key to speed, I try to use as much memory as is available. However, there is the danger of running out of memory. This is where memory usage control

Re: [sqlite] Unrecognized "Z" UTC time zone signifier

2008-02-22 Thread Ralf Junker
Aristotle Pagaltzis wrote: >* [EMAIL PROTECTED] <[EMAIL PROTECTED]> [2008-02-21 13:45]: >> Ralf Junker <[EMAIL PROTECTED]> wrote: >> > SQLite does not recognize "Z" as the zero offset time zone >> > specifier. >> >> If we start

Re: [sqlite] Unrecognized "Z" UTC time zone signifier

2008-02-21 Thread Ralf Junker
[EMAIL PROTECTED] wrote: >Ralf Junker <[EMAIL PROTECTED]> wrote: >> SQLite does not recognize "Z" as the zero offset time zone specifier. > >SQLite does not currently accept any timezone specifiers, other >than a hard-coded timezone offset: > >

[sqlite] Unrecognized "Z" UTC time zone signifier

2008-02-21 Thread Ralf Junker
SQLite does not recognize "Z" as the zero offset time zone specifier. "Z" (for 'Zulu time', an alternative name for UTC) is part of the ISO 8601 standard for date and time representations. See http://en.wikipedia.org/wiki/ISO_8601 for details. In this regard, SQLite does not currently follow

Re: [sqlite] How to specify regular expression in a query?

2008-01-28 Thread Ralf Junker
Hello Nicolas Williams, >I suppose that to make this generic so that users can replace the >regexp, like, and glob functions would require some new interfaces. I believe so, too. The like and glob optimization is part of where.c and outside the reach of sqlite3_create_function(). >SQLite would

Re: [sqlite] How to specify regular expression in a query?

2008-01-28 Thread Ralf Junker
Hello Bharath Booshan L, >>select * from t where filepath regexp '/MyMovie(\.[^\.]+)*$'; > >Will this query use index, if we had one, on filepath? No. It will do a full table scan. Ralf - To unsubscribe, send email

Re: [sqlite] How to specify regular expression in a query?

2008-01-25 Thread Ralf Junker
Hello Bharath Booshan L, yes, with SQLiteSpy you can do this: drop table if exists t; create table t (id integer primary key, filepath text); insert into t values (1, '/Volumes/Backup/MyMovies/MyMovie.mp4'); insert into t values (2, '/Volumes/Backup/MyMovies/Hello.mp4'); insert into t values (3,

Re: [sqlite] Proposed change to sqlite3_trace()

2008-01-11 Thread Ralf Junker
DRH wrote: >Legacy applications should continue to work. You might get a >compiler warning about a type mismatch on the 2nd parameter to >sqlite3_trace(). But calling a 2-parameter function with 3 >parameters is suppose to be harmless in C. Harmless in C, but not so in other languages. I

Re: [sqlite] Proposed change to sqlite3_trace()

2008-01-11 Thread Ralf Junker
Roger Binns wrote: >The biggest problem with the trace api is that there is no way to find >out what the bound parameters were. If an application follows best >practise using bound parameters all over then the trace api is rather >useless. Thanks for bringing this up again. There was a thread

Re: [sqlite] Lemon: Conflicts with repeated TERMINALS

2007-11-29 Thread Ralf Junker
Joe Wilson <[EMAIL PROTECTED]> wrote: >The following grammar may be clearer to you: Yes, it is many thanks! I believe I am making progress! At least I can see the picture much clearer now and was able to come up with the following grammar with just one conflict unsolved: %left NEWLINE.

Re: [sqlite] Undefined collation: Peculiar observations ...

2007-11-29 Thread Ralf Junker
Hello Trevor Talbot, >> Trevor, I am not sure what you mean by "subselect on its own". Is this what >> you are looking for? > >> sqlite> SELECT * FROM (SELECT * FROM a); >> SQL error: no such collation sequence: unknown > >Yes, exactly. I was curious to see if it made any kind of difference.

Re: [sqlite] Lemon: Conflicts with repeated TERMINALS

2007-11-29 Thread Ralf Junker
Many thanks, Joe, >Your grammar is ambiguous. The text tokens run together for >various rules because the grammar lacks clear separators between >them. OK, I begin to understand. The "clear separators" need to be TERMINALs, right? I believed that these were imlicit because there are TEXT and

[sqlite] Lemon: Conflicts with repeated TERMINALS

2007-11-28 Thread Ralf Junker
I am trying to write a Wiki parser with Lemon. The Lemon features suite my needs perfectly, but I am unfortunately stuck with the problem of parsing conflicts. All conflicts seem caused by repeat constructs like this: text ::= textpiece. text ::= text textpiece. The complete grammar

Re: [sqlite] Undefined collation: Peculiar observations ...

2007-11-28 Thread Ralf Junker
>> Imagine that a SQLite3 database opened in a custom application with a >> registered a collation sequence named "unknown" has created the following >> table: >> >> CREATE TABLE a (b COLLATE unknown); >> >> Now open this table in the default SQLite3 CLI. Up to here, everything works >> as

[sqlite] Undefined collation: Peculiar observations ...

2007-11-25 Thread Ralf Junker
Imagine that a SQLite3 database opened in a custom application with a registered a collation sequence named "unknown" has created the following table: CREATE TABLE a (b COLLATE unknown); Now open this table in the default SQLite3 CLI. Up to here, everything works as expected. Now some

[sqlite] Can sqlite3_reset() ever fail?

2007-11-08 Thread Ralf Junker
Hello, I wonder if sqlite3_reset() can ever fail. In particular, does sqlite3_reset() always reset the statement even if it returns an error code? >From the documentation and mailing list, my understanding is that >sqlite3_reset() errors always relate to the latest (or possibly ongoing) VM

Re: [sqlite] How many virtual table implemenations are there out there?

2007-11-02 Thread Ralf Junker
>But to do so seems likely to require an incompatible change to the >virtual-table interface. Could I kindly request an addition to the incompatible change to the virtual-table interface? I would very much appreciate a corresponding function to function xRowID( pCursor:

Re: [sqlite] Retrieve bound host parameters from statement?

2007-10-30 Thread Ralf Junker
Hello Joe Wilson, >> True, but we would need to access unsupported API to do so. And as we know >> only too well, >> unsupported API is subject to change without notice any time ;-). Therefore >> I would rather not >> write these myself but ask for the possibility to add them to the library >>

Re: [sqlite] Retrieve bound host parameters from statement?

2007-10-30 Thread Ralf Junker
Hello Dan Kennedy, >> True, but we would need to access unsupported API to do so. >> And as we know only too well, unsupported API is subject to >> change without notice any time ;-). Therefore I would rather >> not write these myself but ask for the possibility to add them >> to the library

Re: [sqlite] Retrieve bound host parameters from statement?

2007-10-29 Thread Ralf Junker
>> I wonder if it is possible to retrieve bound host parameters from a prepared >> SQL statement? I am >> thinking of the opposite of the sqlite3_bind... family of functions like: >> >> int sqlite3_bound_int (sqlite3_stmt*, int*); >> int sqlite3_bound_double (sqlite3_stmt*, double*); >

[sqlite] Retrieve bound host parameters from statement?

2007-10-29 Thread Ralf Junker
Hello, I wonder if it is possible to retrieve bound host parameters from a prepared SQL statement? I am thinking of the opposite of the sqlite3_bind... family of functions like: int sqlite3_bound_int (sqlite3_stmt*, int*); int sqlite3_bound_double (sqlite3_stmt*, double*); They would be

Re: [sqlite] Lemon: Help on conflic resolution?

2007-10-17 Thread Ralf Junker
Richard, this helped me greatly! I also derived from your example that I can use multiple characters without conflicts like this: --- doc ::= inline_list. // List of allowed characters. Add more as you like. c ::= CHAR. c ::= SPACE. // The c character repeat. chars ::= c. chars

Re: [sqlite] Lemon: Help on conflic resolution?

2007-10-17 Thread Ralf Junker
Richard, this helped me greatly! I also derived from your example that I can use multiple characters without conflicts like this: --- doc ::= inline_list. // List of allowed characters. Add more as you like. c ::= CHAR. c ::= SPACE. // The c character repeat. chars ::= c. chars

[sqlite] Lemon: Help on conflic resolution?

2007-10-17 Thread Ralf Junker
I am writing to ask for help about how to solve The Lemon parser conflicts. As part of a larger grammar, I am need to implement this regular expression in Lemon: (.+|'.+')+ I tried lots of grammars, but all of them generated Lemon warnings. Maybe someone could have a look at the grammar

Re: [sqlite] FTS3 where ?

2007-09-21 Thread Ralf Junker
Hello Andre du Plessis, If you are using Delphi, FTS3 is already included in the latest DISQLite3 (Pro and Personal). Download is available from http://www.yunqa.de/delphi/. The source code is available from CVS. You will find FTS3 in the /ext/ directory. Ralf >Fts3 which everyone is talking

Re: [sqlite] 3.5.0 alpha TryEnterCriticalSection linker error

2007-09-05 Thread Ralf Junker
>Isn't it time to drop the Win9X support from the default build? I do not believe that just because Win9x is missing a single required call justifies dropping support for it altogether! >I'm thinking that any optimization should be enabled for the majority of >users. Or if it's not really an

Re: [sqlite] rowid versus docid for fts3.

2007-09-02 Thread Ralf Junker
llbacks, before I try? Regards, Ralf >On 8/31/07, Ralf Junker <[EMAIL PROTECTED]> wrote: >> This one just came to my mind: >> >> CREATE TABLE (rowid INTEGER PRIMARY KEY, t TEXT); >> >> This promotes "rowid" to a visible column "rowid"

Re: [sqlite] rowid versus docid for fts3.

2007-08-31 Thread Ralf Junker
This one just came to my mind: CREATE TABLE (rowid INTEGER PRIMARY KEY, t TEXT); This promotes "rowid" to a visible column "rowid" which does not change during a VACUUM. "rowid" is already a reserved word in SQLite. Maybe this option is even compatible to FTS2? Ralf >ext/fts3.c in the

RE: [sqlite] Problem loading extension in Delphi (FTS2)

2007-08-16 Thread Ralf Junker
DISQLite3 does not use SQLite.NET. As I read Sam, he did not say so. He just compared the two to support his argument that "loadable extensions are not required to create custom functions and having access to source is not required for custom functions either". Ralf >I was not aware that

Re: [sqlite] Problem loading extension in Delphi (FTS2)

2007-08-16 Thread Ralf Junker
Hello Zlatko Matic, >How about Lazarus version of DISQLite3? :) DISQLite3 is Delphi only at the moment, maybe later! ;-) Ralf - To unsubscribe, send email to [EMAIL PROTECTED]

Re: [sqlite] DISQLite FTS

2007-08-16 Thread Ralf Junker
>Does DISQLite have its own implementation of FTS, so not using FTS2 at >all? DISQLite3 uses the original full text search modules, adapted to Delphi. Both FTS1 and FTS2 are already compiled in, and can both be used by the same application (like SQLiteSpy does). >Does it use the same

Re: [sqlite] Problem loading extension in Delphi (FTS2)

2007-08-16 Thread Ralf Junker
Hello Joe Wilson, >Your product is not useful to a few users like me who require custom >sqlite functions for their databases. I am not sure I understand currectly. Only loadable extensions are currently omited from DISQLite3. sqlite3_create_function() is very well available in DISQLite3 Pro

Re: [sqlite] Problem loading extension in Delphi (FTS2)

2007-08-15 Thread Ralf Junker
Hello Joe Wilson, >Does it support external sqlite loadable extensions? Loadable extensions are currently omitted. FTS1 and FTS2 extensions are provided as built-in modules. User-aware collations sequences using the Windows sorting functions are provided in place of the ICU extension. Full

Re: [sqlite] Problem loading extension in Delphi (FTS2)

2007-08-14 Thread Ralf Junker
Hello Roberto, >Might be a typo, but your declaration defines the calling convention as >'stdcall' (instead of 'cdecl'), was your sqlite3.dll custom built with this >calling convention? I don't think much of sqlite would work with stdcall. DISQLite3 intentionally uses the 'register' calling

Re: [sqlite] Problem loading extension in Delphi (FTS2)

2007-08-10 Thread Ralf Junker
Hello Henrik Ræder, >I'm trying to load the FTS2 extension in Delphi, using the Aducom >components. Am really close, but still stuck, and thinking it's a problem >with the parameter to sqlite3_enable_load_extension(). DISQLite3 (http://www.yunqa.de/delphi/sqlite3/) does not expose such problems.

Re: [sqlite] autoincrement and fts2?

2007-07-17 Thread Ralf Junker
>>The standard way to have non-TEXT information associated with rows in >>an fts table would be a separate table which joins with the fts table >>on rowid. > >I have not tested this, but if the FTS2 rowid is the standard SQLite rowid, I >believe that it will be affected by VACUUM change of

Re: [sqlite] autoincrement and fts2?

2007-07-17 Thread Ralf Junker
>The rowid is the standard SQLite rowid, so it does provide an INTEGER >PRIMARY KEY AUTOINCREMENT column. > >The standard way to have non-TEXT information associated with rows in >an fts table would be a separate table which joins with the fts table >on rowid. I have not tested this, but if the

Re: [sqlite] [Delphi] Escaping quote?

2007-06-27 Thread Ralf Junker
>Question, does the %q operator offer any advantages over calling QuotedStr ? Yes: The %q operator just duplicates internal quotes, it does insert quotes at the beginning and the end of the string like QuotedStr does. You can can still use sqlite3_mprintf's %Q operator for that. Ralf

Re: [sqlite] [Delphi] Escaping quote?

2007-06-26 Thread Ralf Junker
>I'm having a problem saving strings into a colum from a Delphi application >because they might contain the ( ' ) single quote character: > >Is there a function I should call either in SQLite or Delphi before running >the SQL query? Why don't you use the '%q' operator of SQLite's

[sqlite] Ticket #2415

2007-06-15 Thread Ralf Junker
Hello Developers, I notice that you are about to release version 3.4.0 shortly. I have just created ticked #2415 which I believe breaks existing code. Are there any chance that you find the time to look at it prior to 3.4.0? Ralf

Re: [sqlite] Japanese-Korean characters

2007-04-26 Thread Ralf Junker
Hello Ralf Junker, >>Thanks for the link. My OS is Linux. Is there something available on these >>lines for linux ? > >SQLiteSpy apparently runs on Linux with the help of wine, but I have not >tested this myself: http://www.winehq.com/ Here is a small re

Re: [sqlite] Japanese-Korean characters

2007-04-26 Thread Ralf Junker
Hello Pavan, >Thanks for the link. My OS is Linux. Is there something available on these >lines for linux ? SQLiteSpy apparently runs on Linux with the help of wine, but I have not tested this myself: http://www.winehq.com/ Ralf

Re: [sqlite] Japanese-Korean characters

2007-04-26 Thread Ralf Junker
Hello Pavan, >Can we store/retrieve Japanese/korean characters in sqlite db ? Yes, you can well do so, as others have already pointed out. If you are also looking for a Unicode GUI SQLite database manager to display and edit Japanese / Korean character databases, you might want to have a look

Re: [sqlite] FTS: index only, no text storage - Was: [sqlite] FTS: Custom Tokenizer / Stop Words

2007-03-14 Thread Ralf Junker
Scott Hess wrote: >>I am optimistic that the proper implementation will use even less than 50%: > >Indeed :-). Glad to read this ;-) >>I found that _not_ adding the original text turned out to be a great time >>saver. This makes sense if we know that the original text is about 4 times >>the

Re: [sqlite] FTS: index only, no text storage - Was: [sqlite] FTS: Custom Tokenizer / Stop Words

2007-03-13 Thread Ralf Junker
Hello Scott, I was hoping that you would read my message, many thanks for your reply! >UPDATE and DELETE need to have the previous document text, because the >docids are embedded in the index, and there is no docid->term index >(or, put another way, the previous document text _is_ the

Re: [sqlite] FTS: index only, no text storage - Was: [sqlite] FTS: Custom Tokenizer / Stop Words

2007-03-13 Thread Ralf Junker
Ion Silvestru wrote: >Just a question: did you eliminated stop-words in your tests? No, I did not eliminate any stop-words. The two test runs were equal except for the small changes in FTS 2. My stop words question was not intended for source code but for human language texts. Ralf

<    1   2   3   >