Re: [sqlite] problem building reduced-size sqlite

2008-07-21 Thread Shane Harrelson
I checked in some updates to the "configure" support that will hopefully do the right thing and pass any OMIT options to lemon and mkkeywordhash. There was also a minor fix to handle SQLITE_OMIT_VIEW being defined while SQLITE_OMIT_SUBQUERY is undefined in select.c (something you probably rand into

Re: [sqlite] format the date time

2008-07-21 Thread Igor Tandetnik
"Joanne Pham" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have the following statement: > select CURRENT_TIMESTAMP; > the output is : > 2008-07-22 01:10:34 > and I would like to have the following output: > TUE JULY 22 01:10:34 2008 > Is there any function that I can format the

[sqlite] format the date time

2008-07-21 Thread Joanne Pham
Hi All, I have the following statement:     select CURRENT_TIMESTAMP; the output is :     2008-07-22 01:10:34 and I would like to have the following output:     TUE JULY 22 01:10:34 2008 Is there any function that I can format the data to show as above. Thanks JP __

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread C. Smith
> > That was it! It seems to work now. > > // new code > int r = _wcsnicmp((const wchar_t *)a, (const wchar_t *)b, > ((alen < blen) ? alen : blen) / sizeof(wchar_t)); > > Is the fact that the callback strings are not NUL terminated and the > lengths are in bytes documented anywhere? If not,

[sqlite] Format of the data

2008-07-21 Thread Joanne Pham
Hi All, I am current using sqlite 3.5.9 and below is command to get the data from my database as:     .output '/opt/phoenix/monitor/exportData'     .mode csv     select '#Monitored applications' , group_concat(appName) from appMapTable; The output is:     "#Monitored applications","new1,nsc1,Orac

Re: [sqlite] hello, new to list

2008-07-21 Thread Igor Tandetnik
Greg Morphis <[EMAIL PROTECTED]> wrote: > I've been playing around with SQLite for a few days now.. It's pretty > impressive. > I was curious if there were any plans to support right outer joins and > full outer joins? > I was hoping to utilize SQLite for a couple home projects I have > created in

Re: [sqlite] FTS index size

2008-07-21 Thread Scott Hess
On Fri, Jul 18, 2008 at 12:54 AM, Jiri Hajek <[EMAIL PROTECTED]> wrote: > from what I have read about FTS3, it stores the original data as well as the > index needed for fast full-text access. Therefore, in several posts here it > was recommended to use two tables joined one-to-one in case it's nee

[sqlite] hello, new to list

2008-07-21 Thread Greg Morphis
I've been playing around with SQLite for a few days now.. It's pretty impressive. I was curious if there were any plans to support right outer joins and full outer joins? I was hoping to utilize SQLite for a couple home projects I have created in Postgres. I don't think I need a huge horse like Pos

Re: [sqlite] problem building reduced-size sqlite

2008-07-21 Thread Dennis Cote
Steve Friedman wrote: > >case 275: /* trigger_cmd ::= UPDATE orconf nm SET setlist > where_opt */ > { yygotominor.yy243 = sqlite3TriggerUpdateStep(pParse->db, > &yymsp[-3].minor.yy0, yymsp[-1].minor.yy174, yymsp[0].minor.yy172, > yymsp[-4].minor.yy46); } > break; >case

Re: [sqlite] problem building reduced-size sqlite

2008-07-21 Thread Steve Friedman
I rebaselined to the latest CVS as of this morning before rerunning the make command, so the lines have shifted, but the same issues as before. Steve Dennis Cote wrote: > Steve Friedman wrote: >> libtool: compile: gcc -g -O3 -DSQLITE_ENABLE_RTREE=1 -DTEMP_STORE=2 >> -DSQLITE_DEFAULT_CACHE_SIZE

[sqlite] sqite wildcard search with indexing

2008-07-21 Thread CAVALO SCHMIDT
Salutations, Is it possible to do a simple wildcard/regexp-type search in sqlite databases, but with indexing? For example, if I want to search for the string "aCa", we would do only one SELECT * FROM a WHERE a = "aCa", and it would interpret "C" as any letter in "bdgjklmnpqrstv". So, one SELECT w

Re: [sqlite] Does changing the db change result sets?

2008-07-21 Thread Dennis Cote
Roger Binns wrote: > > The cursor object in apsw wraps a prepared statement. Since the cursor > gets reused the earlier results are no longer available: > > cursor.execute("select * from numbers") > ... > cursor.execute("delete from numbers where no=5") > OK, that makes sense. > > Alte

Re: [sqlite] BUG in RTree ?

2008-07-21 Thread Xevi
Thank You, I'll keep looking further. Xevi En/na Kees Nuyt ha escrit: > On Sun, 20 Jul 2008 09:03:44 +0200, you wrote: > > >> Hello to all, >> >> I think I have found a bug in the RTree extension (I'm using version 3.6.0) >> If I run this script : >> > > It works perfectly for me. >

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread C. Smith
>>> int r = _wcsnicmp((const wchar_t *)a, (const wchar_t *)b, >>> (alen < blen) ? alen : blen); > > Maybe the length is still wrong. The lengths passed to an sqlite > collation sequence callback are in bytes. But _wcsnicmp() is > probably in characters, no? > > That was it! It seems to w

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread Dan
On Jul 21, 2008, at 8:10 PM, D. Richard Hipp wrote: > > On Jul 21, 2008, at 8:32 AM, C. Smith wrote: >> >> I didn't know the strings weren't nul terminated. I changed my >> callback to: >> >> static int _cmp(void *pCtx, int alen, const void *a, >> int blen, const void *b) >> { >> int r = _wc

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread C. Smith
> > How did you register the collating sequence? Did you use the > SQLITE_UTF16_ALIGNED argument on the 3rd parameter? > I am doing the below. sqlite3_create_collation(db, "PATH", SQLITE_UTF16, NULL, _cmp); I changed it to use "SQLITE_UTF16_ALIGNED" but it didn't load properly. I modifie

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread D. Richard Hipp
On Jul 21, 2008, at 8:32 AM, C. Smith wrote: > > I didn't know the strings weren't nul terminated. I changed my > callback to: > > static int _cmp(void *pCtx, int alen, const void *a, > int blen, const void *b) > { > int r = _wcsnicmp((const wchar_t *)a, (const wchar_t *)b, > (alen < bl

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread C. Smith
D. Richard Hipp wrote: > On Jul 21, 2008, at 12:05 AM, C. Smith wrote: > >> The collation is >> a case-insensitive wchar compare for windows (using _wcsicmp). > > The strings passed to a collating function are not zero-terminated. > Are you making a copy of both input strings and adding a zero

Re: [sqlite] Select All Tables?

2008-07-21 Thread Igor Tandetnik
"cstrader" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Is there a way to SELECT UNION all of the tables in a database -- > that is to create a big table with rows from each of the individual > tables? I don't see how this is supposed to work, in general. For one thing, tables mi

[sqlite] Select All Tables?

2008-07-21 Thread cstrader
Is there a way to SELECT UNION all of the tables in a database -- that is to create a big table with rows from each of the individual tables? I understand I can do multiple selects, but the command gets very long if there are a lot of tables. Thanks _

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread C. Smith
Robert Simpson wrote: > I just tried the same steps on a memorydb using the NOCASE collation > sequence, and it worked fine ... > > > C:\Src>sqlite3 :memory: > SQLite version 3.6.0 > Enter ".help" for instructions > Enter SQL statements terminated with a ";" > sqlite> .headers on > sqlite> create

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread cstrader
Is there a way to SELECT UNION all of the tables in a database -- that is to create a big table with rows from each of the individual tables? I understand I can do multiple selects, but the command gets very long if there are a lot of tables. Thanks - Original Message - From: "D. Ric

Re: [sqlite] User-defined collation UNIQUE INDEX

2008-07-21 Thread D. Richard Hipp
On Jul 21, 2008, at 12:05 AM, C. Smith wrote: > The collation is > a case-insensitive wchar compare for windows (using _wcsicmp). The strings passed to a collating function are not zero-terminated. Are you making a copy of both input strings and adding a zero terminator yourself, or are you

Re: [sqlite] Diacritics (umlaut) select in SQLite

2008-07-21 Thread Michael Schlenker
Igor Tandetnik schrieb: > "Alexey Pechnikov" <[EMAIL PROTECTED]> wrote in > message news:[EMAIL PROTECTED] >> ? ? ?? Sunday 20 July 2008 21:20:19 Jay A. Kreibich >> ???(?): >>> The good news is that you can re-implement the LIKE function fairly >>> easily. There have been a number of po