a little more details on how I use the extension with sqlite3:
In my shell script, I am running sqlite3 on all files of a folder:
find "./scripts" -iname "*.sql" | while read sqlfile
do
echo " -- ${sqlfile}"
/usr/local/bin/sqlite3 mydb.db3 < $sqlfile;
done
and in my sql script, I am loading the
Here is some tests:
--- csv1.test
+++ csv1.test
@@ -23,10 +23,11 @@
#
# csv-1.*: Creating/destroying csv tables.
# csv-2.*: Linear scans of csv data.
# csv-3.*: Test renaming an csv table.
# csv-4.*: CREATE errors
+# csv-5.*: Dirty header, long line, escaped quotes, escaped newlines.
Proof is in the pudding...
Try this program: It's got two forks going. Does 5000 inserts and 5000
selects simultaneously. (it's not pretty but it works). It shows how many
BUSY times occur for both sections.
Run it without any args and it won't sleep at all.
There are four sleep values of 1
On Tue, May 18, 2010 at 12:50:20PM -0500, Black, Michael (IS) scratched on the
wall:
> Rats on the interprocess locks.
More to the point, database connection mutexes are just for the
database connection. Even the same process with more than one
database connection might fight with each oth
> I was still talking about sleeping for spinning the BUSY return -- but just
> doing it as fast as possible without using much CPU instead of picking 10ms
> which seeem too long to me when the transactions should take sub-millisecond
> times.
What do you mean by this? I don't understand you. C
Rats on the interprocess locks.
I was still talking about sleeping for spinning the BUSY return -- but just
doing it as fast as possible without using much CPU instead of picking 10ms
which seeem too long to me when the transactions should take sub-millisecond
times.
Michael D. Black
Senio
hello,
I am facing a very bizarre issue.
I am on mac os x 64 bits.
I needed a uuid() function that generates GUID.
I created then a dll with Qt like:
#include "/usr/local/include/sqlite3ext.h"
SQLITE_EXTENSION_INIT1
#include
#include
extern "C" void sqlite3_uuid(sqlite3_context *context, int
> Actually I wonder if the sqlite3 mutex calls would be better yet.
> http://www.sqlite.org/c3ref/mutex_alloc.html
They work only inside one process. They won't provide inter-process locks.
> If they do what I think they would guarantee FIFO and fastest possible
> response to the users.
I don'
Actually I wonder if the sqlite3 mutex calls would be better yet. They would
appear to guarantee synchronization and you could just allow them to block when
BUSY or use the try function if you want to timeout.
http://www.sqlite.org/c3ref/mutex_alloc.html
If they do what I think they would gua
On 18 May 2010, at 4:19pm, Black, Michael (IS) wrote:
> Interesting...but that logic means that later processes might get their
> results before earlier ones.
There is no harm in this. In fact it's a characteristic of parallel systems.
If it truly mattered which order the results arrived in,
This is a VB6 procedure (in an ActiveX dll) that handles this.
Obviously there are a lot of secondary routines that you don't have,
but I think you will
get the general idea of what is going on here.
Public Sub vArray2SQLiteTable(strDB As String, _
vArray As Variant,
On Tue, May 18, 2010 at 10:19:32AM -0500, Black, Michael (IS) scratched on the
wall:
> Interesting...but that logic means that later processes might get
> their results before earlier ones.
Yes, but that's true regardless. We're talking about parallel
operation on what may or may not be MP/M
> You'll get fairer resolution of busy contention with a fixed timeout. Just
> do 10ms 50 times. That way the first guy in should get the first results.
Don't fool yourself. There's no value of timeout that will guarantee
fairness. Just consider this scenario:
process #1 - BUSY, sleep 10
proce
Interesting...but that logic means that later processes might get their results
before earlier ones.
Imagine this:
process #1 hits BUSY -- sleep 9,10,11,12,13,14,15
Shortly after the sleep 15 process#2 comes in
process #2 hits BUSY -- sleep 9 -- gets lock - returns (note process#1 is still
sl
On Tue, May 18, 2010 at 7:35 AM, Black, Michael (IS) wrote:
> I think I see a potential problem with your logic. You say "up to 2
> seconds" and "up to 4 times". So it sounds like you're doing a 500ms sleep
> on your retry with 4 tries?
>
Actually no, not just 4 retries. What I did was use so
On Tue, 18 May 2010 13:18:49 +0100, Bart Smissaert
wrote:
>Quite simple that. Basically: range > variant array > loop through
>array and write to SQLite.
>Let me know and I will post some example code.
If you have some basic code to go through Excel or OO sheets to gather
data and somehow stick t
On Tue, 18 May 2010 15:04:35 +0100 (BST), Swithun Crowe
wrote:
>You don't get the exception message because the exec method doesn't throw
>an exception. It puzzled me for a bit.
Right, it doesn't raise an exception :-/ I had to look at
/var/log/lighttpd/error.log.
Thank you.
__
On Tue, 18 May 2010 15:57:37 +0200, Michal Seliga
wrote:
>I think this is not really sqlite related, i am using fastcgi with nginx
>server and when security became in issue i had similar problems
>quick solution - do 'chmod -R 777 /srv/www' and you will see if problem
>is related to rights or if
Hello
GG> Could it be that the Www directory is off-limit to PHP scripts in
GG> write mode? FWIW, PDO can succesfully find and open db.sqlite:
The directory itself should be writeable by the lighttpd user, as sqlite
will want to create temporary journal files in the same directory. So
being ab
Hello,
many thanks for your answer,
I tried the command "file" on the current lib that I just built
(by ./configure CFLAGS="-DSQLITE_ENABLE_ICU `icu-config --cppflags`"
LDFLAGS="`icu-config --ldflags`")
it gives:
$ file /usr/local/lib/libsqlite3.dylib
/usr/local/lib/libsqlite3.dylib: Mach-O 64-b
I think this is not really sqlite related, i am using fastcgi with nginx
server and when security became in issue i had similar problems
quick solution - do 'chmod -R 777 /srv/www' and you will see if problem
is related to rights or if its something else
also i think you should use absolute paths
On Tue, 18 May 2010 14:30:06 +0100 (BST), Swithun Crowe
wrote:
>If you use PDO, then you get access to Sqlite 3.x databases:
>
>http://www.php.net/manual/en/ref.pdo-sqlite.php
Thanks for the input. After following the following article, I
successfully installed Lighttpd in FastCGI mode + PHP5 and
Hello
GG> I'd like to use SQLite from some PHP5 scripts, either on Linux or
GG> Linux.
A wise choice either way!
GG> What is the right way to set things up so that I can use a recent
GG> release of SQLite (apparently, the SQLite that comes with PHP by
GG> default is a 2.x release)?
If you use
On May 18, 2010, at 4:14 AM, Sylvain Pointeau wrote:
> but is it 64 bits? or do I have to add a special option?
Last time I built a Universal Binary sqlite3 on OS X (March 2010 3.6.22) I had
to
CFLAGS='-arch i686 -arch x86_64' LDFLAGS='-arch i686 -arch x86_64' ./configure
--disable-dependency
Hello
I'd like to use SQLite from some PHP5 scripts, either on Linux or
Linux.
What is the right way to set things up so that I can use a recent
release of SQLite (apparently, the SQLite that comes with PHP by
default is a 2.x release)?
Thank you.
___
> how to read Excel/OO files and somehow put them into an SQLite database
> for better use.
Quite simple that. Basically: range > variant array > loop through
array and write to SQLite.
Let me know and I will post some example code.
RBS
On Tue, May 18, 2010 at 11:56 AM, Gilles Ganault wrote:
>
I think I see a potential problem with your logic. You say "up to 2 seconds"
and "up to 4 times". So it sounds like you're doing a 500ms sleep on your
retry with 4 tries?
What you could easiliy hit is the probability that on each time you ask for a
lock it could be busy doing the inserts you
On Tue, 18 May 2010 11:48:06 +0100, Bart Smissaert
wrote:
>You can run SQL on sheet ranges.
>Just need to make sure that the workbook is saved and closed as there is a bug
>to do with ADO causing a memory leak.
Thanks for the tip. I'll investigate in-place querying in Excel and OO
Calc, and if it
You can run SQL on sheet ranges.
Just need to make sure that the workbook is saved and closed as there is a bug
to do with ADO causing a memory leak.
RBS
On Tue, May 18, 2010 at 11:19 AM, Gilles Ganault wrote:
> On Mon, 17 May 2010 22:55:47 -0700, Matt Young
> wrote:
>>I have that problem. A s
On Mon, 17 May 2010 22:55:47 -0700, Matt Young
wrote:
>I have that problem. A solution is an ultra lite SQLite window to
>play along side existing spread sheet packages. Then just get read and
>write to the spreadsheet happening.
Right. There a millions of users who have stuffed data in Excel
be
On Mon, 17 May 2010 20:31:07 +0200, Henk Pretorius
wrote:
>Try SQLite Manager - a FireFox add on, but can also run stand-alone as
>a XUL application.
Thanks, I'll see if it can show data entry forms so non-technies can
handle their database safely.
http://code.google.com/p/sqlite-manager/
_
hello,
I am generally doing:
./configure
make
sudo make install
for having sqlite in my /usr/local/ directory.
but is it 64 bits? or do I have to add a special option?
Best regards,
Sylvain
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://
32 matches
Mail list logo