Re: [sqlite] Can I search all tables and columns of SQLite database for a specific text string?

2020-02-15 Thread John G
error "too many fields" } } } dbcmd eval $SQL { puts [format "Field %-15s on %-15s has the string %-15s: %s" $cn $tn $searchstr $val] } Field t0c on table0 has the string plus : 2 plus 2 equals 4 Field t12 on table1

Re: [sqlite] Can I search all tables and columns of SQLite database for a specific text string?

2020-02-13 Thread Scott
handling a combination of SQL statements and looping arrays. Thanks for your help guys! Scott ValleryEcclesiastes 4:9-10 On Thursday, February 13, 2020, 09:35:54 AM EST, Simon Slavin wrote: On 13 Feb 2020, at 2:01pm, Scott wrote: > Can I search all tables and columns of SQLite d

Re: [sqlite] Can I search all tables and columns of SQLite database for a specific text string?

2020-02-13 Thread Jose Isaias Cabrera
Scott, on Thursday, February 13, 2020 09:01 AM, wrote... > > Can I search all tables and columns of SQLite database for a specific > text string? I'm sure this question has been asked many times, but I'm > having trouble finding a solid answer. > My problem: My clien

Re: [sqlite] Can I search all tables and columns of SQLite database for a specific text string?

2020-02-13 Thread Simon Slavin
On 13 Feb 2020, at 2:01pm, Scott wrote: > Can I search all tables and columns of SQLite database for a specific text > string? No. There's no way to do this, and there's no way to say "all tables" in SQL. In other words it's not easy to write such a thing. I

[sqlite] Can I search all tables and columns of SQLite database for a specific text string?

2020-02-13 Thread Scott
Can I search all tables and columns of SQLite database for a specific text string? I'm sure this question has been asked many times, but I'm having trouble finding a solid answer. My problem: My clients SQLite database has 11 tables and multiple columns (some designated and others not

Re: [sqlite] Can I search all tables and columns of SQLite database for a specific text string?

2020-02-13 Thread Thomas Kurz
I would create an SQL dump ("sqlite3 file.db .dump") and search therein. - Original Message - From: Scott To: SQLite Mailing List Sent: Thursday, February 13, 2020, 15:01:06 Subject: [sqlite] Can I search all tables and columns of SQLite database for a specific text stri

Re: [sqlite] Database speed comparison

2020-01-11 Thread Andy
And huge speedup by exec("BEGIN") myloop exec("COMMIT") sob., 11 sty 2020 o 07:30 Andy napisał(a): > I had sqlite3_prepare_v2 without sqlite3_finalize and sqlite3_close not > closes multiple databases. > > sob., 11 sty 2020 o 07:17 Andy napisał(a): > >> These tests are a lot faster than calling

Re: [sqlite] Database speed comparison

2020-01-10 Thread Andy
I had sqlite3_prepare_v2 without sqlite3_finalize and sqlite3_close not closes multiple databases. sob., 11 sty 2020 o 07:17 Andy napisał(a): > These tests are a lot faster than calling Sqlite in my program, I must use > the same convention: for example first prepare, next sqlite3_bind_int64, >

Re: [sqlite] Database speed comparison

2020-01-10 Thread Andy
These tests are a lot faster than calling Sqlite in my program, I must use the same convention: for example first prepare, next sqlite3_bind_int64, sqlite3_bind_text and sqlite3_step. My calling was very not optimal. pt., 10 sty 2020 o 20:13 Simon Slavin napisał(a): > Are you aware of > >

Re: [sqlite] Database speed comparison

2020-01-10 Thread Edward Lau
I would be nice to have that page updated and contrast the old and new performance of SQLite. -Original Message- From: Cecil Westerhof To: SQLite mailing list Sent: Fri, Jan 10, 2020 10:37 am Subject: [sqlite] Database speed comparison I ran across this page:     https://sqlite.org

Re: [sqlite] Database speed comparison

2020-01-10 Thread Simon Slavin
Are you aware of ? Now all you have to do is write comparative tests for other SQL implementations. However, from what I've seen, realistic speed tests tend to come down to cache sizes. ___ sqlite-

Re: [sqlite] Database speed comparison

2020-01-10 Thread Andy
I like to compare these tests on my computer. My first attempt to Sqlite works but a lot of slower and I don't know why, maybe due to inserting blobs? But blobs are small, about 10 kB. pt., 10 sty 2020 o 19:37 Cecil Westerhof napisał(a): > I ran across this page: > https://sqlite.org/speed.h

[sqlite] Database speed comparison

2020-01-10 Thread Cecil Westerhof
I ran across this page: https://sqlite.org/speed.html It is a 'bit' outdated. (It uses 2.7.6.) Where can I find the scripts? And would it be a lot of work to update them and regularly rerun them? If it is manageable I would not mind to provide regularly updates. -- Cecil Westerhof __

[sqlite] Sharing an SQLite database across containers

2020-01-10 Thread Simon Slavin
" Just exactly how is a file under constant modification safely shared across dozens of containers, all needing concurrent access? And you’re really going to read this file from compl

Re: [sqlite] Sqlite database gets corrupted

2019-12-20 Thread Simon Slavin
On 20 Dec 2019, at 12:11pm, Syed Ahmad wrote: > Any way to recover it. This mailing list strips attachments. When's the last time you could use this file ? Did it have any form of encryption ? Was it usable with your own software ? Could you open it with the SQLite command-line tool ?

[sqlite] Sqlite database gets corrupted

2019-12-20 Thread Syed Ahmad
Hi, Operating system: Embedded Linux. Version : 3.14.2 2016-09-12 sqlite3 bad.sqlite "PRAGMA integrity_check" Error: file is encrypted or is not a database I have attached the file. Any way to recover it. Is any there at fixes in latest sqlite version 3.x. which will fix this issue. Thanks

Re: [sqlite] database disk image is malformed

2019-11-15 Thread Peter da Silva
I have been bitten by this a couple of times, so now I'm super-conservative about how I deal with this. What I do is have any parent database setup done by having the parent spawn a child process to do the actual database work, and return any data the parent needs in the status or (if more than a

Re: [sqlite] database disk image is malformed

2019-11-15 Thread Rowan Worth
) is, I think, how Linux?/POSIX? deals with file-locks on > the underlying file-handle. IIRC, if both parent/child process share a > file-handle, and one of them closes that file, then ALL file-level > locks (which is what SQLite uses) on that handle are released: not > just the ones cre

Re: [sqlite] database disk image is malformed

2019-11-15 Thread Simon Slavin
On 15 Nov 2019, at 8:03am, Graham Holden wrote: > What I *think* this may mean is that re-spawned children will inhereit > the open file-handle of the SQLite connection opened by the parent > after it initially fired all child processes. That's not a problem. > Even if the (re-spawned) > child

Re: [sqlite] database disk image is malformed

2019-11-15 Thread Graham Holden
I've been having problems with my email system... I don't think earlier attempts at sending have made it to the list, but if they did, apologies for any duplication... Monday, November 11, 2019, 5:46:05 PM, Jukka Marin wrote: >> On 11 Nov 2019, at 5:13pm, Jukka Marin wrote: >> >> > The main pr

Re: [sqlite] database disk image is malformed

2019-11-12 Thread Andreas Kretzer
Just to make sure, you didn't oversee that (like I was ...): Daemonizing a process is also a fork() - and this invalidates your connection! I used the daemon() function in my program (together with a few other processes) that used a DB connection. I opened this connection _before_ I called daemon

Re: [sqlite] database disk image is malformed

2019-11-12 Thread Jukka Marin
On Mon, Nov 11, 2019 at 05:37:37PM +, Simon Slavin wrote: > On 11 Nov 2019, at 5:13pm, Jukka Marin wrote: > > > The main process first opens the databases and checks that their > > version matches that of the software and if not, the databases are > > closed and initialized by running a scrip

Re: [sqlite] database disk image is malformed

2019-11-11 Thread Simon Slavin
On 11 Nov 2019, at 5:13pm, Jukka Marin wrote: > The main process first opens the databases and checks that their > version matches that of the software and if not, the databases are > closed and initialized by running a script. > > After closing the databases, main process forks the children and

Re: [sqlite] database disk image is malformed

2019-11-11 Thread Jukka Marin
On Mon, Nov 11, 2019 at 05:03:25PM +, Simon Slavin wrote: > On 11 Nov 2019, at 1:42pm, Jukka Marin wrote: > > > Or does the main process need to close all databases, then fork, then > > reopen the databases? > > Which processes access the databases ? The main process ? Its children ? > A

Re: [sqlite] database disk image is malformed

2019-11-11 Thread Shawn Wagner
rform database operations using the already opened > > > databases. > > > > > > From > > > > https://sqlite.org/howtocorrupt.html#_carrying_an_open_database_connection_across_a_fork_ > > > : > > > > > > > Do not open

Re: [sqlite] database disk image is malformed

2019-11-11 Thread Simon Slavin
On 11 Nov 2019, at 1:42pm, Jukka Marin wrote: > Or does the main process need to close all databases, then fork, then > reopen the databases? Which processes access the databases ? The main process ? Its children ? Are they all using the same connection ? Are they all trying to use the same

Re: [sqlite] database disk image is malformed

2019-11-11 Thread Jukka Marin
e operations using the already opened > > databases. > > > > From > > https://sqlite.org/howtocorrupt.html#_carrying_an_open_database_connection_across_a_fork_ > > : > > > > > Do not open an SQLite database connection, then fork(), then try to

Re: [sqlite] database disk image is malformed

2019-11-08 Thread Jukka Marin
qlite.org/howtocorrupt.html#_carrying_an_open_database_connection_across_a_fork_ > : > > > Do not open an SQLite database connection, then fork(), then try to use > that database connection in the child process. All kinds of locking > problems will result and you can easily en

Re: [sqlite] database is empty but intact

2019-11-07 Thread Simon Slavin
On 8 Nov 2019, at 12:40am, Roman Fleysher wrote: > I am using linux, I think this analyzer is windows only. "Precompiled Binaries for Linux" > Maybe I should ask a different question: Would knowing answer to my question > (is it possible for DB to become em

Re: [sqlite] database is empty but intact

2019-11-07 Thread Roman Fleysher
LoM as the cause of the problem? Roman From: sqlite-users [sqlite-users-boun...@mailinglists.sqlite.org] on behalf of Simon Slavin [slav...@bigfraud.org] Sent: Thursday, November 07, 2019 7:28 PM To: SQLite mailing list Subject: Re: [sqlite] database is

Re: [sqlite] database is empty but intact

2019-11-07 Thread Simon Slavin
On 8 Nov 2019, at 12:03am, Roman Fleysher wrote: > I am using command line sqlite3 with -vfs unix-none. This disables locking > within SQLite. Instead, locking is provided externally by FLoM (distributed > file lock manager). I asked questions in a thread "disable file locking > mechanism ove

[sqlite] database is empty but intact

2019-11-07 Thread Roman Fleysher
Dear SQLiters, I am using command line sqlite3 with -vfs unix-none. This disables locking within SQLite. Instead, locking is provided externally by FLoM (distributed file lock manager). I asked questions in a thread "disable file locking mechanism over the network". It is possible that FLoM ha

Re: [sqlite] database disk image is malformed

2019-11-07 Thread Shawn Wagner
This line stood out: > The main process opens the databases and then forks the other processes which can then perform database operations using the already opened databases. From https://sqlite.org/howtocorrupt.html#_carrying_an_open_database_connection_across_a_fork_ : > Do not open an

[sqlite] database disk image is malformed

2019-11-07 Thread Jukka Marin
Dear List, I'm developing software which keeps parameters and real-time data in SQLite databases on a x86_64/linux system. I am getting "database disk image is malformed" errors from SQLite when using select. Some select operations succeed, some fail. This happens on multiple systems. I would

Re: [sqlite] Multiple files for a single SQLite database

2019-10-31 Thread Keith Medcalf
about anticipated traffic volume. >-Original Message- >From: sqlite-users On >Behalf Of Aydin Ozgur Yagmur >Sent: Thursday, 31 October, 2019 05:40 >To: SQLite mailing list >Subject: Re: [sqlite] Multiple files for a single SQLite database > >How can it be raised to

Re: [sqlite] Multiple files for a single SQLite database

2019-10-31 Thread Aydin Ozgur Yagmur
Oh, I found the answer. SQLITE_MAX_ATTACH should be changed. On Thu, Oct 31, 2019 at 2:40 PM Aydin Ozgur Yagmur wrote: > How can it be raised to 125? > I tried to change with calling "sqlite3_limit(db_, SQLITE_LIMIT_ATTACHED, > 125)" but there is no effect. > I still get "too many attached data

Re: [sqlite] Multiple files for a single SQLite database

2019-10-31 Thread Warren Young
On Oct 31, 2019, at 5:40 AM, Aydin Ozgur Yagmur wrote: > > How can it be raised to 125? Define SQLITE_MAX_ATTACHED at build time: https://www.sqlite.org/limits.html#max_attached > I tried to change with calling "sqlite3_limit(db_, SQLITE_LIMIT_ATTACHED, > 125)" but there is no effect. Tha

Re: [sqlite] Multiple files for a single SQLite database

2019-10-31 Thread Aydin Ozgur Yagmur
How can it be raised to 125? I tried to change with calling "sqlite3_limit(db_, SQLITE_LIMIT_ATTACHED, 125)" but there is no effect. I still get "too many attached databases" exception. On Wed, Oct 30, 2019 at 5:01 PM David Raymond wrote: > "There's a limit, somewhere around ten, I think. Thou

Re: [sqlite] Multiple files for a single SQLite database

2019-10-30 Thread J. King
On October 30, 2019 9:58:20 a.m. EDT, Simon Slavin wrote: >There are things you cannot split across different database files. For >instance, you cannot declare a FOREIGN KEY that refers to a table in a >different schema. Because SQLite can't be sure you'll have that schema >available. It's als

Re: [sqlite] Multiple files for a single SQLite database

2019-10-30 Thread David Raymond
"There's a limit, somewhere around ten, I think. Though you can increase it by explicitly messing with limits and compilation options." Default is 10, can be raised to 125. ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://maili

Re: [sqlite] Multiple files for a single SQLite database

2019-10-30 Thread Simon Slavin
On 30 Oct 2019, at 1:41pm, Aydin Ozgur Yagmur wrote: > SQLite stores a single database in a single file. > > According to the specific project requirements and due to the performance > concerns; > > When working with large databases, is it possible to explicitly tell SQLite > not to store the

[sqlite] Multiple files for a single SQLite database

2019-10-30 Thread Aydin Ozgur Yagmur
SQLite stores a single database in a single file. According to the specific project requirements and due to the performance concerns; When working with large databases, is it possible to explicitly tell SQLite not to store the whole DB in a single file and store different tables in different file

[sqlite] Problem saving datatable back to the sqlite database

2019-10-21 Thread Brad Henderson
Hello, I would appreciate any help in finding why I get an error when saving back to a database. I am using vb.net in VS-2019 with sqlite. The error is: "Concurrency violation: the UpdateCommand affected 0 of the expected 1 records." I have worked out that the error only occurs whe

Re: [sqlite] sqlite database changes not committed immediately

2019-10-03 Thread Wintech Tech
act that there's a Highway to Hell but only a Stairway to Heaven says > a lot about anticipated traffic volume. > > >-Original Message- > >From: sqlite-users On > >Behalf Of Wintech Tech > >Sent: Thursday, 3 October, 2019 04:06 > >To: sqlite-users@m

Re: [sqlite] sqlite database changes not committed immediately

2019-10-03 Thread Keith Medcalf
qlite-users On >Behalf Of Wintech Tech >Sent: Thursday, 3 October, 2019 04:06 >To: sqlite-users@mailinglists.sqlite.org >Subject: [sqlite] sqlite database changes not committed immediately > >Hi everyone , > >i have posted below Questions on other forums , Please help me s

[sqlite] sqlite database changes not committed immediately

2019-10-03 Thread Wintech Tech
Hi everyone , i have posted below Questions on other forums , Please help me solve this System.Data.SQLite error . (both are same errors) https://dba.stackexchange.com/questions/249902/sqlite-database-changes-not-commited-immediately https://stackoverflow.com/questions/58116937/auto-increment

Re: [sqlite] database like file archive

2019-08-28 Thread Rowan Worth
On Tue, 27 Aug 2019 at 21:57, Peng Yu wrote: > I haven't found an archive format that allows in-place delete (I know > that .zip, .7z and .tar don't). This means that whenever delete is > needed, the original archive must be copied first. This can be > problematic when the archive is large and th

Re: [sqlite] database like file archive

2019-08-27 Thread Richard Hipp
On 8/27/19, Jens Alfke wrote: > is [SQLite] engineered with the > assumption that a database file may be malicious, or is the assumption > "garbage in, garbage out"? https://www.sqlite.org/security.html https://www.sqlite.org/testing.html Our intent is that SQLite database

Re: [sqlite] database like file archive

2019-08-27 Thread Keith Medcalf
nipulated as >> does everything else. > The layout of a Zip file is vastly simpler than a SQLite database. > A Zip codec does not include an interpreter for a sophisticated > programming language. > Zip files do not contain program code that runs when the file is > read; SQLi

Re: [sqlite] database like file archive

2019-08-27 Thread Jens Alfke
anks. My question was simply whether SQLite itself is considered safe when operating on an untrusted database file. > Even ZIP files have a database schema that can be manipulated as does > everything else. The layout of a Zip file is vastly simpler than a SQLite database. A Zip co

Re: [sqlite] database like file archive

2019-08-27 Thread Keith Medcalf
On Tuesday, 27 August, 2019 12:47, Jens Alfke wrote: >Archive files often get transferred between people. Using this format >for that purpose would involve opening and reading untrusted SQLite >database files. Is that safe? Could maliciously corrupting the schema >or other m

Re: [sqlite] database like file archive

2019-08-27 Thread Simon Slavin
On 27 Aug 2019, at 7:47pm, Jens Alfke wrote: > Archive files often get transferred between people. Using this format for > that purpose would involve opening and reading untrusted SQLite database > files. Is that safe? Could maliciously corrupting the schema or other > metadata o

Re: [sqlite] database like file archive

2019-08-27 Thread Jens Alfke
> On Aug 27, 2019, at 7:06 AM, Philip Bennefall wrote: > > There is the sqlar archive format, which you can test using the official > sqlite3 command line shell. There is also a library for it as part of the > Sqlite3 repository. "An SQLite Archive is an ordinary SQLit

Re: [sqlite] database like file archive

2019-08-27 Thread Peng Yu
> The standard "sqlite3" command-line tool will read and write SQLite > archive files. See the documentation at > https://www.sqlite.org/sqlar.html#managing_an_sqlite_archive_from_the_command_line OK. So there is basically no need to install the sqlar command since all features from the sqlar com

Re: [sqlite] database like file archive

2019-08-27 Thread Philip Bennefall
The earliest version of the shell which ships with the archive support is 3.22.0, according to the page I linked to. If you have an earlier version you could simply grab the Mac OSX precompiled binaries from the download page on sqlite.org and you'll be good to go. Kind regards, Philip Benn

Re: [sqlite] database like file archive

2019-08-27 Thread Richard Hipp
On 8/27/19, Peng Yu wrote: > > How to install it? In homebrew's sqlite package, I don't find sqlar. I > use Mac OS X. > The standard "sqlite3" command-line tool will read and write SQLite archive files. See the documentation at https://www.sqlite.org/sqlar.html#managing_an_sqlite_archive_from_th

Re: [sqlite] database like file archive

2019-08-27 Thread Peng Yu
> There is the sqlar archive format, which you can test using the official > sqlite3 command line shell. There is also a library for it as part of > the Sqlite3 repository. > > https://www.sqlite.org/sqlar.html > https://sqlite.org/sqlar/doc/trunk/README.md This is good to know. How to install i

Re: [sqlite] database like file archive

2019-08-27 Thread Dominique Devienne
https://sqlite.org/sqlar/doc/trunk/README.md On Tue, Aug 27, 2019 at 3:57 PM Peng Yu wrote: > Hi, > > I haven't found an archive format that allows in-place delete (I know > that .zip, .7z and .tar don't). This means that whenever delete is > needed, the original archive must be copied first. Th

Re: [sqlite] database like file archive

2019-08-27 Thread Philip Bennefall
There is the sqlar archive format, which you can test using the official sqlite3 command line shell. There is also a library for it as part of the Sqlite3 repository. https://www.sqlite.org/sqlar.html Kind regards, Philip Bennefall On 8/27/2019 3:56 PM, Peng Yu wrote: Hi, I haven't found a

[sqlite] database like file archive

2019-08-27 Thread Peng Yu
Hi, I haven't found an archive format that allows in-place delete (I know that .zip, .7z and .tar don't). This means that whenever delete is needed, the original archive must be copied first. This can be problematic when the archive is large and the file to delete is small. Something along the li

Re: [sqlite] Making blob as a sqlite database.

2019-05-28 Thread Keith Medcalf
sers- >boun...@mailinglists.sqlite.org] On Behalf Of Mohd Radzi Ibrahim >Sent: Tuesday, 28 May, 2019 21:23 >To: SQLite mailing list >Subject: Re: [sqlite] Making blob as a sqlite database. > >Hi Don, >I am working on sales and stock management systems where all outlets >run on >it

Re: [sqlite] Making blob as a sqlite database.

2019-05-28 Thread Simon Slavin
On 29 May 2019, at 4:22am, Mohd Radzi Ibrahim wrote: > But it seems that the blob in SQLite could not do that. You can read/write to a BLOB as if it's a file. <https://sqlite.org/c3ref/blob_open.html> You just can't address the BLOB as if it's a SQLite database. T

Re: [sqlite] Making blob as a sqlite database.

2019-05-28 Thread Mohd Radzi Ibrahim
Hi Don, I am working on sales and stock management systems where all outlets run on it's own local database. I was thinking of a solution for all outlets to backup to central server and perhaps thru web interface do some queries on the backup database. I know postgres has binary interface that allo

Re: [sqlite] Making blob as a sqlite database.

2019-04-30 Thread Don V Nielsen
Sorry to bother, Mohd. What is your use case? I mentioned this to developers around me and they are intrigued. You are storing a database file as blob in a database? We are curious as to the application. I am assuming the database being stored is a collection of sensor or event data? On Fri, Apr 2

Re: [sqlite] Making blob as a sqlite database.

2019-04-26 Thread Richard Hipp
On 4/26/19, Mohd Radzi Ibrahim wrote: > Hi, is there a vfs that could be used to open a blob column as a database? I think you probably want the sqlite3_deserialize() interface. https://www.sqlite.org/c3ref/deserialize.html -- D. Richard Hipp d...@sqlite.org

[sqlite] Making blob as a sqlite database.

2019-04-26 Thread Mohd Radzi Ibrahim
Hi, is there a vfs that could be used to open a blob column as a database? thanks. Radzi. ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Database corruption check.

2019-04-15 Thread Richard Hipp
On 4/15/19, Tim Streater wrote: >> >> This command was added to the command-line tool recently. > > 3.19.3 has it - that's almost two years ago. > The .selftest command was added on 2017-03-09 by https://www.sqlite.org/src/timeline?c=f4fcd46f08ba59d2 and hence as likely first in release 3.18.0 on

Re: [sqlite] Database corruption check.

2019-04-15 Thread Tim Streater
On 15 Apr 2019, at 11:02, Simon Slavin wrote: > On 15 Apr 2019, at 10:36am, Lullaby Dayal wrote: > >> Thank you very much for your response. The link seems to be helpful. But I >> fail to run the .selftest command from my sqlite3 prompt. I got the error: >> unknown command or invalid arguments e

Re: [sqlite] Database corruption check.

2019-04-15 Thread Dominique Devienne
On Mon, Apr 15, 2019 at 11:37 AM Lullaby Dayal wrote: > [...]. But I fail to run the .selftest command from my sqlite3 prompt. I > got the error: > unknown command or invalid arguments error. > That code dates back to July 2017. So you must have a very old version. > I am a newbie in SQLite. I

Re: [sqlite] Database corruption check.

2019-04-15 Thread Simon Slavin
On 15 Apr 2019, at 10:36am, Lullaby Dayal wrote: > Thank you very much for your response. The link seems to be helpful. But I > fail to run the .selftest command from my sqlite3 prompt. I got the error: > unknown command or invalid arguments error. This command was added to the command-line tool

Re: [sqlite] Database corruption check.

2019-04-15 Thread Lullaby Dayal
running in QNX on an ARM board. Thank you! Lullaby On Sun, Apr 14, 2019, 5:38 PM Richard Hipp On 4/14/19, Lullaby Dayal wrote: > > > > For Sqlite database, as per my understanding, implementing pragma > > integrity_check won't guarantee all errors to be detected. > >

Re: [sqlite] Database corruption check.

2019-04-14 Thread Richard Hipp
On 4/14/19, Lullaby Dayal wrote: > > For Sqlite database, as per my understanding, implementing pragma > integrity_check won't guarantee all errors to be detected. Maybe you are confused with "PRAGMA quick_check"? The "PRAGMA integrity_check" takes a little lon

[sqlite] Database corruption check.

2019-04-14 Thread Lullaby Dayal
Hi, We are using sqlite for our embedded automotive system based on QNX. We have a requirement to check whether database is corrupted on start-up and replace it with default database if such a scenario happens. For Sqlite database, as per my understanding, implementing pragma integrity_check

Re: [sqlite] Backing up a SQLite database without the CLI

2019-04-04 Thread Bohwaz/Fossil
If you're trying to copy a file while connections still have it open then you should use SQLite API calls to do it. The obvious ones are in the SQLite Online Backup API, which is the set of calls underlying the '.backup' command you mentioned. You can find documentation for this here:

Re: [sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Paul
As I was using the unchanged nuget package I assumed it would be a “default” encryption as it isn’t something I compiled or changed? Tithras Sent from my iPhone > On 1 Apr 2019, at 15:33, Simon Slavin wrote: > >> On 1 Apr 2019, at 3:30pm, Mattock Paul wrote: >> >> Thanks, do we have any ide

Re: [sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Simon Slavin
On 1 Apr 2019, at 3:30pm, Mattock Paul wrote: > Thanks, do we have any idea on what Algorithm is used? Since more than one algorithm is available, this would be something selected by the software you were using. So I can only suggest you read the source code for the bit of the software which

Re: [sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Mattock Paul
Simon, Thanks, do we have any idea on what Algorithm is used? Tithras > On 01 April 2019 at 14:28 Simon Slavin wrote: > > > On 1 Apr 2019, at 1:15pm, Mattock Paul wrote: > > > Just to confirm I am using the nuget package (System.Data.SQLite v1.0.109.2) > > This uses PCL Crypto, which in tur

Re: [sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Simon Slavin
On 1 Apr 2019, at 1:15pm, Mattock Paul wrote: > Just to confirm I am using the nuget package (System.Data.SQLite v1.0.109.2) This uses PCL Crypto, which in turn accesses crypto implemented in PCL itself rather than implmenting its own. A list of crypto methods it supports, tabled against OS,

Re: [sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Mattock Paul
Jim, Thanks for the information. Just to confirm I am using the nuget package (System.Data.SQLite v1.0.109.2) and my sqlite database is encrypted without any additional modules associated with my release. A code snippet of the section which handles the initial database encryption is as follows

Re: [sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Jim Borden
3_key binding shows that it is not present in the library (which makes sense since it is guarded by an #if in the source base) On 2019/04/01 18:27, "sqlite-users on behalf of Mattock Paul" wrote: All, Would anyone be able to confirm what cipher is used for encrypting an SQLit

[sqlite] Database Encryption (System.Data.SQLite)

2019-04-01 Thread Mattock Paul
All, Would anyone be able to confirm what cipher is used for encrypting an SQLite database when password="" is used? I have seen old posts online which state its 128bit but assume this is now wrong and am after completing a design document which requires I state the encryp

Re: [sqlite] Get SQLite Database from React Native mobile app

2019-03-25 Thread Simon Slavin
On 25 Mar 2019, at 6:45am, Ashu Thakkar wrote: > How to get Database created from react native mobile app. <https://aboutreact.com/example-of-sqlite-database-in-react-native/> ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite

Re: [sqlite] [EXTERNAL] Get SQLite Database from React Native mobile app

2019-03-25 Thread Hick Gunter
2019 07:45 An: sqlite-users@mailinglists.sqlite.org Betreff: [EXTERNAL] [sqlite] Get SQLite Database from React Native mobile app Hello, How to get Database created from react native mobile app. Thank You ___ sqlite-users mailing list sqlite-users

[sqlite] Get SQLite Database from React Native mobile app

2019-03-25 Thread Ashu Thakkar
Hello, How to get Database created from react native mobile app. Thank You ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

Re: [sqlite] Backing up a SQLite database without the CLI

2019-03-22 Thread Scott Perry
lways be empty at this point). > > Any other thoughts welcome though! > Cheers, > Jonathan > > On 2019-03-18 13:37, Simon Slavin wrote: >> On 18 Mar 2019, at 1:10pm, Jonathan Moules >> wrote: >> >>> I was wondering if there was a good way of back

Re: [sqlite] Backing up a SQLite database without the CLI

2019-03-18 Thread Simon Slavin
On 18 Mar 2019, at 3:21pm, Jonathan Moules wrote: > At this point I'm starting to think that the best option is to create a new > database with the requisite structure and copy the data across via an ATTACH > (there are only two tables and one will almost always be empty at this point). That c

Re: [sqlite] Backing up a SQLite database without the CLI

2019-03-18 Thread Shawn Wagner
18 Mar 2019, at 1:10pm, Jonathan Moules > wrote: > > > >> I was wondering if there was a good way of backing up an SQLite > database if you do *not* have access to the SQLite command line tool (which > I know has .backup - https://stackoverflow.com/a/25684912). [snip] >

Re: [sqlite] Backing up a SQLite database without the CLI

2019-03-18 Thread Jonathan Moules
:10pm, Jonathan Moules wrote: I was wondering if there was a good way of backing up an SQLite database if you do *not* have access to the SQLite command line tool (which I know has .backup - https://stackoverflow.com/a/25684912). [snip] I've considered simply running "PRAGMA wal_checkp

Re: [sqlite] Backing up a SQLite database without the CLI

2019-03-18 Thread Simon Slavin
On 18 Mar 2019, at 1:10pm, Jonathan Moules wrote: > I was wondering if there was a good way of backing up an SQLite database if > you do *not* have access to the SQLite command line tool (which I know has > .backup - https://stackoverflow.com/a/25684912). [snip] > I've

[sqlite] Backing up a SQLite database without the CLI

2019-03-18 Thread Jonathan Moules
Hi List, I was wondering if there was a good way of backing up an SQLite database if you do *not* have access to the SQLite command line tool (which I know has .backup - https://stackoverflow.com/a/25684912). The new VACUUM INTO (https://www.sqlite.org/lang_vacuum.html#vacuuminto) is not an

Re: [sqlite] Database backup with writers present?

2019-02-28 Thread Wout Mertens
I meant reflinks not extents. I should go to bed ;) Wout. On Thu, Feb 28, 2019 at 11:57 PM Wout Mertens wrote: > One option, if you are on a filesystem supporting extents (macOS's apfs > and Linux's btrfs only, currently, with xfs and bcachefs support on the > horizon): do a copy with reflinks

Re: [sqlite] Database backup with writers present?

2019-02-28 Thread Wout Mertens
One option, if you are on a filesystem supporting extents (macOS's apfs and Linux's btrfs only, currently, with xfs and bcachefs support on the horizon): do a copy with reflinks (cp -c on macOS, cp --reflink=auto elsewhere). That should be super fast since all it does is point to existing data and

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Simon Slavin
On 27 Feb 2019, at 4:16pm, Richard Hipp wrote: > On 2/27/19, Stephen Chrzanowski wrote: >> Does write blocking still come into play when using "vaccum into", > > The VACUUM INTO command is a reader. So (in WAL mode) some other > process can continue writing while the VACUUM INTO is running. T

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Richard Hipp
On 2/27/19, Stephen Chrzanowski wrote: > Does write blocking still come into play when using "vaccum into", The VACUUM INTO command is a reader. So (in WAL mode) some other process can continue writing while the VACUUM INTO is running. -- D. Richard Hipp d...@sqlite.org ___

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Stephen Chrzanowski
Does write blocking still come into play when using "vaccum into", or are writes put into the WAL file? I know that with the regular backup API, any writes to the DB restarts the backup process, but I hadn't thought about putting either into a transaction. (I'm an I-D-TEN-T, I know) On Wed, Feb

Re: [sqlite] Database backup with writers present?

2019-02-27 Thread Richard Hipp
On 2/27/19, Daniel Polski wrote: > > Is there some way to take a snapshot of a database regardless if there > comes new writes / transactions while doing the backup, and just write a > copy of that snapshot as it was into a new database file? I assume you are using WAL mode? If not, you should b

[sqlite] Database backup with writers present?

2019-02-27 Thread Daniel Polski
Hello, When reading the docs I don't get a clear understanding on what strategy I could/should use to backup a heavily used database (with frequent reads & writes). I have one application (A) with multiple threads reading & writing to the database. Application (A) handles write locking intern

Re: [sqlite] "Pickling" an in-memory SQLite database.

2019-01-31 Thread Thomas Levine
If sqlite3_serialize and sqlite3_deserialize are not exposed in your bindings, I suppose you can do something like with NamedTemporaryFile(mode='rb', prefix=prefix) as tmp: c = sqlite3.connect(tmp.name) # Do stuff. c.close() serialized = tmp.file.read() where "prefix" is a RAM fi

Re: [sqlite] "Pickling" an in-memory SQLite database.

2019-01-31 Thread Shawn Wagner
k back on > open. It would be convenient and attractive for me, for a plugin I am > writing for this application, to be able to use an in-memory SQLite > database, and then squirrel the DB away with everything else in the > application file. That way, everything would be stored un

[sqlite] "Pickling" an in-memory SQLite database.

2019-01-31 Thread Randall Smith
database, and then squirrel the DB away with everything else in the application file. That way, everything would be stored under one roof, so to speak. My question: Is there a good way to "pickle" a SQLite database into a block of bytes for storage, and then "unpickle" i

  1   2   3   4   5   6   7   8   9   10   >