Re: [sqlite] completion of sql words

2011-04-12 Thread Roger Binns
and provides the callback when tab is pressed. Due to readline's licensing there is funky stuff going on on Mac. If the above clues do not help then please send me private email and I'll work with you to get this working for you. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux

Re: [sqlite] Sqlite database corrupted

2011-04-10 Thread Roger Binns
#how_to_corrupt The chance of there being a bug in SQLite is extremely small. First of all some of the other billions of users would have noticed. Secondly the testing is extraordinary: http://www.sqlite.org/testing.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux

Re: [sqlite] How is the page-cache filled?

2011-04-09 Thread Roger Binns
calls are made - VFS. However controlling when and why they are made are in the pager code. When you work on the real SQLite source you'll find pager.c and pcache.c. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http

Re: [sqlite] completion of sql words

2011-04-09 Thread Roger Binns
. It would be nice if there were virtual tables allowing dynamic introspection of SQLite. (*) In a fit of OCD it even pays attention to what case you are using and does completions in the same case even if you mix cases in the same word! Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU

Re: [sqlite] completion of sql words

2011-04-09 Thread Roger Binns
the behaviours are a little inconsistent: http://code.google.com/p/apsw/issues/detail?id=115 Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk2g1JgACgkQmOOfHg372QTjRQCcDVMaLLR27OQWCVI/4R7yTVZ3 j

[sqlite] sqlite3_analyze doesn't run on OSX 10.6.7

2011-03-30 Thread Roger Wehage
Mac OS X 10.6.7 MacBook Pro 2.4 GHz Intel Core 2 Duo /Users/roger/Desktop roger-wehages-macbook-pro:Desktop roger$ ./sqlite3_analyzer dyld: Library not loaded: /usr/local/lib/libtcl8.6.dylib Referenced from: /Users/roger/Desktop/./sqlite3_analyzer Reason: image not found Trace/BPT trap

Re: [sqlite] Full Table Scan after Analyze

2011-03-26 Thread Roger Binns
will predominantly be sequential access. These factors are why it is a not a trivial determination as to which is better and why analyze helps. It is also why an index can be slower more commonly than expected. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG

Re: [sqlite] sqlite3_close( ) error

2011-03-23 Thread Roger Binns
it used after free. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk2K2bMACgkQmOOfHg372QTPtACffp7nZHH7jhEm9NZajdFIsC5b FTwAnA94RsFAVunK8NFY757zDOtqnABv =B25D -END PGP SIGNATURE

Re: [sqlite] sqlite3_open16 and flags

2011-03-10 Thread Roger Binns
for sqlite3_open16 you'll see that it converts the filename to UTF8 and then calls the normal open routine. sqlite3_open16_v2 would just do the same thing, so you can achieve the same affect by converting the filename to utf8 yourself and calling sqlite3_open_v2. Roger -BEGIN PGP SIGNATURE- Version

Re: [sqlite] Implementing sequence nextval in sqlite

2011-03-08 Thread Roger Binns
://sqlite.org/support.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk114joACgkQmOOfHg372QT31gCfWnaWAHyBxeo+kBrSuq13I8n3 SkgAnRfUN595yjeH6qU0obADpwCE+6IU =c+YD -END PGP SIGNATURE

Re: [sqlite] Implementing sequence nextval in sqlite

2011-03-08 Thread Roger Binns
in advance and instead just do the actual inserts then use last_insert_rowid to find out what was assigned (everything wrapped in a transaction to avoid concurrency issues). That will unambiguously always give the right answer no matter how sequences are implemented behind the scenes. Roger

Re: [sqlite] Attaching vfs

2011-03-06 Thread Roger Binns
to access data in other formats then use virtual tables. There are no issues with attach and virtual tables. In general you can make the first parameter to your virtual table be the name of the file it should use. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] Feature request: hash function for fast indices on text and blob fields

2011-03-06 Thread Roger Binns
by getting it listed at the end of http://sqlite.org/contrib where you can see a good 'extension-functions.c' to follow. If the team see the extension being downloaded a lot then that is a good case for migrating it into the core. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU

Re: [sqlite] FTS4 bug: last_insert_rowid() fail

2011-03-06 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 See also http://www.sqlite.org/src/tktview?name=13137dccf3 Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] Attaching vfs

2011-03-06 Thread Roger Binns
not being from different VFS, but that can only be changed by additions to the syntax and/or API so it won't help you now. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] adding fdopen to VFS?

2011-03-01 Thread Roger Binns
docs: http://lwn.net/Articles/347547/ http://code.google.com/p/seccompsandbox/wiki/overview Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1tLiMACgkQmOOfHg372QQlxgCgjEyFPKg8KT2riZitw6hcX/78

Re: [sqlite] adding fdopen to VFS?

2011-02-28 Thread Roger Binns
that in Unix in many years. I shipped product in 1994 that used it extensively (a master daemon would use accept() and then pass the new file handles to child processes as appropriate). I_SENDFD is the magic needed. The topic is even covered in Stevens. Roger -BEGIN PGP SIGNATURE- Version

Re: [sqlite] adding fdopen to VFS?

2011-02-28 Thread Roger Binns
initialized. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1sB70ACgkQmOOfHg372QTFkwCgioqwaibI+6WrMedG4L0KOPKJ E5UAoLXUimQ3sLncdOiJL2Gbb+Nouvzb =NonM -END PGP SIGNATURE

Re: [sqlite] adding fdopen to VFS?

2011-02-28 Thread Roger Binns
filenames then (on Linux) the filename could be passed as /proc/self/fd/NN. The default unix vfs could be changed such that filename pattern is recognized and NN+1 is treated as the journal etc. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla

Re: [sqlite] adding fdopen to VFS?

2011-02-28 Thread Roger Binns
function. Now make sure it is tested, kept up to date, works with the platform SQLite etc. It will work, but it is ugly. The question is if there is a better way. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] VFS

2011-02-22 Thread Roger Binns
in the sqlite3*, That should just point to the VFS used. There is no copying or modification. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1j6FkACgkQmOOfHg372QTR8gCgsX+dYtQFkeYRZDskwKoQRXdc

Re: [sqlite] VFS

2011-02-22 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/22/2011 02:39 PM, Robert Hairgrove wrote: On Tue, 2011-02-22 at 08:46 -0800, Roger Binns wrote: What you think you are seeing is not happening. The documentation is correct. OK ... but what about that which the GDB debugger is seeing

Re: [sqlite] oracle compatibility mode

2011-02-22 Thread Roger Binns
OFFSET/LIMIT to get the same effect. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEUEARECAAYFAk1kiM8ACgkQmOOfHg372QRNGgCYwmNSsuv/Wlx8g2jto0HEbk3g jACePLS3PQdxUGl/5LY7qujePXLpv0Y= =wV+/ -END PGP SIGNATURE

Re: [sqlite] SQLite server using execnet ?

2011-02-21 Thread Roger Binns
you have to use Javascript which is slowly becoming the most popular language for that kind of thing including on the desktop. (Eg see node.js and Seed.) Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] Scrolling through results of select

2011-02-21 Thread Roger Binns
the query started. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1jMKcACgkQmOOfHg372QTfbQCgoO3rzpBFmcZIZf2FKJitXaWv t7AAniZ//1kazi0NIXFeUoGCqTkUwKs3 =ISAF -END PGP SIGNATURE

Re: [sqlite] Implementing custom xRead() and xWrite() routines for sqlite3_vfs

2011-02-20 Thread Roger Binns
to be somewhere secure and discreet and to contain valuable items. Roger ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Implementing custom xRead() and xWrite() routines for sqlite3_vfs

2011-02-20 Thread Roger Binns
administration, backups etc. It is not a good idea to defeat those. Alternatively provide this all SaaS style so that everything lives on systems you control with a web interface. That way the data and the encryption keys will not be living on an arbitrary end user system. Roger -BEGIN PGP SIGNATURE

Re: [sqlite] SQLite server using execnet ?

2011-02-20 Thread Roger Binns
. If transactions and ACID matter then carefully research what meets your needs and deploying using as much redundancy and backup as appropriate. If you can't make your mind up, write a server that provides your data REST style and make the clients use HTTP. Roger -BEGIN PGP SIGNATURE- Version

Re: [sqlite] Fwd: Scrolling through results of select

2011-02-20 Thread Roger Binns
is to 'CREATE TEMP TABLE results AS ...select...'. This will also work if someone uses ORDER BY random() or any other udf that depends on more than its arguments. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] Upgrade from 3.5.8 - 3.7.5 - increase memory usage

2011-02-20 Thread Roger Binns
malloc. The application never used more than 10MB and it is currently using 57+MB and continues to climb. The single most likely explanation is this is WAL in action, the memory is from a memory mapped file and a WAL checkpoint will release it. http://www.sqlite.org/wal.html Roger -BEGIN

Re: [sqlite] SQLite server using execnet ?

2011-02-20 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/20/2011 06:23 PM, Jay A. Kreibich wrote: On Sun, Feb 20, 2011 at 05:23:09PM -0800, Roger Binns scratched on the wall: If you want to use SQL then use Postfix. I might suggest PostgreSQL instead. (Sorry, Roger, I couldn't resist.) Yeah

Re: [sqlite] Implementing custom xRead() and xWrite() routines for sqlite3_vfs

2011-02-19 Thread Roger Binns
. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1gaZ4ACgkQmOOfHg372QRiQACfRDeVyC6Z8pTSNwsIvMJLukfv knYAoLWDSilcXoxwAzJyrTTn0eU+Wo2k =Qfrv -END PGP SIGNATURE

Re: [sqlite] Implementing custom xRead() and xWrite() routines for sqlite3_vfs

2011-02-19 Thread Roger Binns
be worse. The backup API knows how to copy from a database that is in use, so you will always get a valid output no matter what is happening to the source. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] Is it possible to determine how many openconnections are active for a sqlite database?

2011-02-19 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 02/19/2011 09:25 PM, Frank Chang wrote: I wanted to thank Roger Binns for solving my problem. You are welcome :-) I was able to determine the sqlite database was corrupted Just to be clear for people finding this thread in the future

Re: [sqlite] EXT :Re: Compiler warnings in R-Tree code under Visual StudioExpress

2011-02-18 Thread Roger Binns
/testing.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1fILIACgkQmOOfHg372QR5bgCfWAnrGbqJfzNowomv3qdUC9VS y+4AnRHszeAS5Sx2kpxYvruV9uv77Fm+ =sy8h -END PGP SIGNATURE

Re: [sqlite] SQLite and SIGFPE

2011-02-18 Thread Roger Binns
sqlite select 1/0.0; INSERT INTO table VALUES(NULL); sqlite select abs(-9223372036854775808); Error: integer overflow Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] iIs it possible to determine how many open connections are active for a sqlite database?

2011-02-18 Thread Roger Binns
connection (same process or not). If there should be multiple accessors then setting a busy timeout is probably the most appropriate solution. See also: http://www.sqlite.org/lockingv3.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla

Re: [sqlite] completion of sql words

2011-02-12 Thread Roger Binns
completion support (quite tricky to do!), colour output, easy extensibility, nicer dumps etc. If you have APSW installed then you can do this to run it: python -c 'import apsw;apsw.main()' dbfilename Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG

Re: [sqlite] SQLite version 3.7.6 testing

2011-02-12 Thread Roger Binns
will there be any problems? Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1Wz40ACgkQmOOfHg372QTtSQCfTUQW3FYJDn8wxzV8l5OSK3DF wioAn0NGzuCn5rD/k96W5HS33m6ww6Fp =/deb -END PGP SIGNATURE

Re: [sqlite] SQLite version 3.7.6 testing

2011-02-12 Thread Roger Binns
I would love most in SQLite is a way of providing a query indicating it will be run a lot in the future and SQLite can do whatever it wants to then make it go faster, such as running ANALYZE, making indices etc. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using

Re: [sqlite] UPDATE/INSERTing 1-2k rows slower than expected

2011-02-12 Thread Roger Binns
.html http://blogs.msdn.com/b/oldnewthing/archive/2010/09/09/10059575.aspx http://peter-zaitsev.livejournal.com/11177.html http://brad.livejournal.com/2116715.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http

Re: [sqlite] SQLite version 3.7.6 testing

2011-02-12 Thread Roger Binns
with stat2 and run analyze, then it is unlikely they will be able to make use of the stat2 information. You can make ANALYZE take a numerical argument or a word such as FULL or QUICK to explicitly choose which flavour is used. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] sqlite async

2011-02-09 Thread Roger Binns
code from the SQLite team means it gets tested like this: http://www.sqlite.org/testing.html How much test code would you need to write to be at the same level? Or maybe you can spare one I/O thread after all :-) Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] Feature Request: PRAGMA foreign_key_list(tableName) should display the name of the foreign key constraint

2011-02-08 Thread Roger Binns
and as feedback for something official like that in SQLite. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1SGLsACgkQmOOfHg372QTIzACgy1ZRHM00YcYSl3uWbJHDq0z4 WtYAoKDNPDNirO+HpUae+t5yfLEIVHnC =0bqk -END PGP

Re: [sqlite] Question about database design

2011-02-02 Thread Roger Binns
://en.wikipedia.org/wiki/Database_normalization SQLite books: http://www.sqlite.org/books.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEUEARECAAYFAk1KCYcACgkQmOOfHg372QRC1gCfbaE7tCvNKFKNkq9N14tSTOzh

Re: [sqlite] SQLite version 3.7.5 - code freeze

2011-01-26 Thread Roger Binns
. The third needs to be turned into an Exception while NOTFOUND can be appropriately handled. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk1AeRUACgkQmOOfHg372QRThgCfX1pPMMzNRdjvcxapNGKhtCdx

Re: [sqlite] SQLite version 3.7.5 - code freeze

2011-01-25 Thread Roger Binns
that indicates syncing is optional.) Changing things that way is a little more intrusive but is a better long term way of structuring things than the short term expedient way SQLITE_FCNTL_SYNC has been implemented. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] SQLite version 3.7.5 - code freeze

2011-01-25 Thread Roger Binns
. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0/rw4ACgkQmOOfHg372QRmIQCgxejja5bgcIxzyADc17rFIaiY fjkAoIp9CqKhC9fjfNe7yu56pIV6dni2 =6RsW -END PGP SIGNATURE

Re: [sqlite] SQLite version 3.7.5 - code freeze

2011-01-24 Thread Roger Binns
for this is unchanged in many revisions of SQLite but is getting errors from the existing VFS. Trying to track down the cause ... Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0+L8YACgkQmOOfHg372QT7ZgCcClSCEqpuM

Re: [sqlite] SQLite version 3.7.5 - code freeze

2011-01-24 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 01/24/2011 06:05 PM, Roger Binns wrote: I'm finding custom VFS code is no longer working at all. The cause is a new xFileControl operation SQLITE_FCNTL_SYNC which appears to needlessly duplicate the existing xSync method. Additionally unlike

Re: [sqlite] Select statement not returning any result

2011-01-16 Thread Roger Binns
to blow your mind a little further, SQLite happily allows zero length table and columns names. This works. CREATE TABLE ( ); INSERT INTO VALUES(3); SELECT + FROM ; Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http

Re: [sqlite] R: R: Crypto lib for Sqlite - suggest required

2011-01-10 Thread Roger Binns
it from a few hundred dollars to a few thousand. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0rNOQACgkQmOOfHg372QSb8QCgl68DWt2EBFon1z7GjUVtCfyR 1xYAoMi4Gd7I2yOu0Mx6J+x3z7L+dMMF =ENvt -END PGP

Re: [sqlite] R: R: Crypto lib for Sqlite - suggest required

2011-01-09 Thread Roger Binns
the SQLite authors since you know it works and gets the security right and will continue to do so. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0p8GEACgkQmOOfHg372QShCQCgr6BIWQMXJ9ZiJvLEYKe+Js43

Re: [sqlite] R: Crypto lib for Sqlite - suggest required

2011-01-08 Thread Roger Binns
- they had to put in deliberate effort. Then throw in some mountweazels: http://en.wikipedia.org/wiki/Fictitious_entry#Motivations_for_creation http://en.wikipedia.org/wiki/Trap_street This would give you enough evidence to sue a competitor. Roger -BEGIN PGP SIGNATURE- Version: GnuPG

Re: [sqlite] Corrupted database file.

2011-01-08 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 01/05/2011 11:05 AM, Greg Morehead wrote: Any insights on how this could occur would be greatly appreciated. http://www.sqlite.org/lockingv3.html#how_to_corrupt Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] last_insert_rowid() question

2010-12-27 Thread Roger Binns
last_insert_rowid(); END).fetchall()[0][0] Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0ZSkcACgkQmOOfHg372QQ0dQCg0F6r7uz46OeT6HlfbEKVj7Mt aNAAnRGhOcrgJrLOiN1VFsCZhE+YXiP+ =1Jlk -END PGP

Re: [sqlite] Rollback transaction if error

2010-12-27 Thread Roger Binns
behind the scenes: with connection: connection.execute(... whatever ...) Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0ZlVMACgkQmOOfHg372QSnYQCfUKEmiN+ZWW/DldLPz3/6dC09

Re: [sqlite] Virtual table optimization using xBestIndex/xFilter

2010-12-19 Thread Roger Binns
index, hence xBestIndex to find the index and xFilter not needing much extra information to work with the selected index. You could probably do something like have the hex address of a data structure as the string. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] sqlite3 backup

2010-12-19 Thread Roger Binns
the backup API and a dumper that provides complete output. It also has a shell that you can extend from Python. (Disclosure: I am the APSW author.) http://apidoc.apsw.googlecode.com/hg/backup.html http://apidoc.apsw.googlecode.com/hg/shell.html Roger -BEGIN PGP SIGNATURE- Version

Re: [sqlite] What is sqlite3_stmt_readonly for?

2010-12-09 Thread Roger Binns
hole hasn't been answered. Whatever Fossil was vulnerable to that needed this emergency fix is something that could affect the rest of us. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] What is sqlite3_stmt_readonly for?

2010-12-08 Thread Roger Binns
/fdiff?v1=68a30b40cb6fde3dv2=6b2674f05c467a3c Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk0ATD8ACgkQmOOfHg372QTZUwCgtBt3gY50XsLCA37IeKTG1w/3 rOgAoL6daZt6gaFk9uI8iVJdDxG21Q7e =h/5B -END PGP

Re: [sqlite] SQLite-3.7.4 Amalgamation?

2010-12-07 Thread Roger Binns
have been nice if there had been a least little forewarning and consultation. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkz/EuUACgkQmOOfHg372QSQ6wCgh2UNn2KQk5FWLXw62aEnBMiF

Re: [sqlite] virtual tables

2010-11-23 Thread Roger Binns
are talking about virtual tables as in the functionality builtin to SQLite - you issue SQL queries that the SQLite query parser and optimiser use and provide backend data: http://www.sqlite.org/vtab.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG

Re: [sqlite] connection-specific user data in extensions

2010-11-22 Thread Roger Binns
) but I can't implement it without great risk of memory corruption as I can't control what elsewhere does with the pointer. There are also some data structures that are not reference counted such as the VFS so you don't know if it is safe to remove or change at any point. Roger -BEGIN PGP

Re: [sqlite] virtual tables

2010-11-22 Thread Roger Binns
level language like Python: http://apidoc.apsw.googlecode.com/hg/example.html#example-vtable Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkzrZUwACgkQmOOfHg372QR1CQCZAaOBwSBoMuBWdM5q0vONUqCp

Re: [sqlite] connection-specific user data in extensions

2010-11-22 Thread Roger Binns
calls have to go via a function pointer table not directly to SQLite so it can't simultaneously be a Python extension and a SQLite extension, although I guess the pointer table could be faked. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla

Re: [sqlite] How to disable and enable constraints in SQLite ?

2010-11-20 Thread Roger Binns
nicer dumps than the SQLite shell (eg there are comments in it) and you can easily add your own commands if you want to provide a more interactive experience doing the data importing. http://apidoc.apsw.googlecode.com/hg/vtable.html http://apidoc.apsw.googlecode.com/hg/shell.html Roger -BEGIN

Re: [sqlite] How to disable and enable constraints in SQLite ?

2010-11-20 Thread Roger Binns
this it is a requirement that the VFS API versions match hence the message. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkzoAy8ACgkQmOOfHg372QSCYwCeKjU0JeBJ5/6jhk/h1Z7tnzt5

Re: [sqlite] SQLite really SLOW on Solaris?

2010-11-20 Thread Roger Binns
that sqliteDefaultBusyCallback tries when USLEEP is available: { 1, 2, 5, 10, 15, 20, 25, 25, 25, 50, 50, 100 } Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] threads and last_insert_rowid()

2010-11-15 Thread Roger Binns
semantics be changed so that the error code and string become thread local just like errno and GetLastError are, but DRH didn't want to do this because there *may* be code out using SQLite that does calls in one thread and retrieves error information in a different one. Roger -BEGIN PGP SIGNATURE

Re: [sqlite] SQLite doesn't recognize newly added table

2010-11-13 Thread Roger Binns
issues. If that doesn't catch anything then it is likely an I/O issue (eg doing a write and then a read of the same area doesn't give the same data back). You can enable I/O tracing by compiling with -DSQLITE_ENABLE_IOTRACE and doing whatever else is required for it to output the traces. Roger

Re: [sqlite] uncertainty how load_extension is supposed to work

2010-11-12 Thread Roger Binns
names for SQLite extensions. My test extension has the imaginative filename under all operating systems of testextension.sqlext. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] Constraint name?

2010-11-12 Thread Roger Binns
of virtual tables. This is very easy to do: plug - my Python wrapper: http://apidoc.apsw.googlecode.com/hg/vtable.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] improvement for the shell

2010-11-12 Thread Roger Binns
a dot command to set the cautious length, make it freely available and see how many people pounce on your new functionality :-) Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] Constraint name?

2010-11-11 Thread Roger Binns
2006. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkzc008ACgkQmOOfHg372QQ/PwCeOnP/uTGfD64q4ftx3opsjnxL LbAAoOAoBdxBCMuNuYB0nnCS1O11152J =bttU -END PGP SIGNATURE

Re: [sqlite] Constraint name?

2010-11-11 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/11/2010 09:40 PM, Roger Binns wrote: A ticket that has been open on this topic since January 2006. Oops, forgot to paste: http://www.sqlite.org/src/tktview?name=23b2128201 Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU

Re: [sqlite] Question about SQLite features.

2010-11-11 Thread Roger Binns
are really arguing is that the SQLite developers should do this work for you, then I'm sure they'd be happy to give you a quote. Start here: http://www.hwaci.com/sw/sqlite/prosupport.html#mods Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG

Re: [sqlite] Ratio of test code to database code

2010-11-10 Thread Roger Binns
percentage of the codebase it covers. Say if that is just lines or decision points (MCDC). Say what kinds of testing there are (eg correctness, memory allocation, data integrity etc). Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http

Re: [sqlite] C Extensions to SQLite

2010-11-04 Thread Roger Binns
or sorting which mainly means a collation. However it is usually better to store an additional column with the formatted data rather than have functions repeatedly called whenever SQLite needs to access the row. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using

Re: [sqlite] How to Online Backup In-Memory DB with SQL?

2010-10-30 Thread Roger Binns
to do (eg sleep, retry, give up after however many retries etc). That is hard to express in SQL. such as pysqlite in python. APSW has had the functionality since SQLite introduced it. pysqlite had it added to the development code this week. http://groups.google.com/group/python-sqlite Roger

Re: [sqlite] Fw: sqlite3 support

2010-10-29 Thread Roger Binns
://www.sqlite.org/lockingv3.html#how_to_corrupt Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkzK18AACgkQmOOfHg372QSZ6ACfeT7PkNx3WQW+0uTUtnavsNfj VLMAoJDIjiN9V9RpIqBnyMFcJrbubZGE =Lu5C -END PGP SIGNATURE

Re: [sqlite] Slow SELECT Statements in Large Database file

2010-10-29 Thread Roger Binns
. Are you aware that SQLite has an RTree extension (written by one of the SQLite developers) that seems to substantially overlap with what you are doing? http://www.sqlite.org/rtree.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http

Re: [sqlite] Problem dumping a single line ot UTF8 text into a table (likely a n00b problem)

2010-10-28 Thread Roger Binns
the encoding as a space or cpu optimization, but this is *very* unlikely to be the space/cpu issue with your application. Yes, I know about surrogate pairs and no I won't mention how they could complicate matters. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG

Re: [sqlite] Loss of Binary Data in Dump File

2010-10-27 Thread Roger Binns
. However SQLite does not actually check that it is valid UTF8 encoding. Consequently it is possible to insert random binary data using the text APIs and for it appear to all work correctly. The dump code stops at the first null in any text value but will correctly output a blob value. Roger

Re: [sqlite] Loss of Binary Data in Dump File

2010-10-27 Thread Roger Binns
as is likely the case for your situation. At the SQL level you use X prefix and hex: insert values( X'7f3c22005d' ) using the PHP PDO API... A Google search found these: http://bugs.php.net/bug.php?id=41135 http://bugs.php.net/bug.php?id=42443 Roger -BEGIN PGP SIGNATURE

Re: [sqlite] programmatic way of determining fragmentation?

2010-10-21 Thread Roger Binns
that you can determine a measure of how bad the fragmentation is, and your code can be quick and crude. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkzAU7UACgkQmOOfHg372QQRkwCfUFLhRUwAVzLb1dOUOkADKl+s

[sqlite] Re : restore function

2010-10-15 Thread Roger Martinez
thank you for answer Igor At once , i didn't knew if i could use restore function with sqlite corrupt database file .It seems that if i use corrupt file or empty file, restore function failed . With database file and table dropped it's ok Regards Roger

[sqlite] Re : restore function

2010-10-15 Thread Roger Martinez
thank you De : Igor Tandetnik itandet...@mvps.org À : sqlite-users@sqlite.org Envoyé le : Jeu 14 octobre 2010, 2h 28min 18s Objet : Re: [sqlite] restore function Roger MARTINEZ roger.martine...@yahoo.fr wrote: restore function is not ok for me . Before I make

[sqlite] restore function

2010-10-13 Thread Roger MARTINEZ
---   - 0   main    /home/roger/htdocs/essai/spip/config/bases/spip.save ... sqlite.restore spip.sqlite spip.save Error: unknown database spip.sqlite it's the same with sqlite3.7.3 ; bug? thank you for answer Roger

Re: [sqlite] create_function_v2 destructor bug or doc issue

2010-10-11 Thread Roger Binns
ways it fails, error codes and any side effects. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkyzKf4ACgkQmOOfHg372QRqwwCeJ0bTJotF27/JnvCCCmAMZlmX sPcAn01LyBvUqVImexZ6CC/bv608BvMh =4aJc -END PGP

Re: [sqlite] Create Read-only Database

2010-10-10 Thread Roger Binns
the database using the journal to get it back into a correct state which involves writing. Heck even while you have it open and idle, a writer could have started a transaction and crashed requiring recovery. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG

Re: [sqlite] Create Read-only Database

2010-10-10 Thread Roger Binns
time has no value you could code something similar yourself if that is what your needs are.) Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkyyae0ACgkQmOOfHg372QRHwACgkLVkD3Y0dWw0vzLRlKk0yeGJ

[sqlite] create_function_v2 destructor bug or doc issue

2010-10-10 Thread Roger Binns
the source to work out. I guess it is too late to change the code to avoid the destructor on error conditions so this behaviour should be documented. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] SQLite working with C++'s iostream

2010-10-04 Thread Roger Binns
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 10/03/2010 10:01 PM, Max Vlasov wrote: On Sun, Oct 3, 2010 at 7:21 PM, Roger Binns rog...@rogerbinns.com wrote: Also note that xTruncate may be called to make a file longer. Roger, are you sure about that? That has certainly been stated

Re: [sqlite] SQLite working with C++'s iostream

2010-10-03 Thread Roger Binns
rather than trying to glue to io::stream directly. My documentation may also provide some insight: http://apidoc.apsw.googlecode.com/hg/vfs.html Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] SQLite working with C++'s iostream

2010-10-03 Thread Roger Binns
also ideally make sure that if the data source is a local file then the same file being opened by regular SQLite will be ok and not cause corruption. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

Re: [sqlite] SQLite working with C++'s iostream

2010-10-03 Thread Roger Binns
to return an xor'd file instance and then override the latter's xRead and xWrite to xor the data before passing to the parents xRead/xWrite. With VFS it is good practise to punt to as much existing code as possible, only providing overridden methods where your VFS adds value. Roger -BEGIN PGP

Re: [sqlite] errors after sqlite3_step

2010-10-02 Thread Roger Binns
implementation that is always correct. 2. If ignoring #1, prove that the network disk implementation is correct before blaming SQLite. 3. Watch out for other background tag-a-longs causing weird behaviour on Windows. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment

Re: [sqlite] errors after sqlite3_step

2010-10-02 Thread Roger Binns
networked filesystems. There isn't a secret setting specifically disabled that when enabled would fix this for you. Ok, there is one and you can't use WAL and you won't get multi-client concurrency: http://www.sqlite.org/cvstrac/wiki?p=ProxyLocking Roger -BEGIN PGP SIGNATURE- Version: GnuPG

Re: [sqlite] Pivot Sequential Data into Dynamic Groups

2010-09-30 Thread Roger Binns
transformation. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAkylBlQACgkQmOOfHg372QQbRgCgka+9KrobMczbj+HutwfrooHg e6wAoK5QgEVgKc5tSfDYUvi2l+UvlciL =Pgun -END PGP SIGNATURE

<    1   2   3   4   5   6   7   8   9   10   >