[Solved] Text management in a database?

Everything else that doesn't fall into one of the other PB categories.
Dude
Addict
Addict
Posts: 1907
Joined: Mon Feb 16, 2015 2:49 pm

[Solved] Text management in a database?

Post by Dude »

Sorry, please ignore this, I just realized the approach won't even work for my situation, as multiple threads would be writing to the database at once, which introduces a major risk of corruption. Better to keep it separate. Sorry for the post.
Last edited by Dude on Sun Sep 15, 2019 4:38 am, edited 1 time in total.
User avatar
skywalk
Addict
Addict
Posts: 3995
Joined: Wed Dec 23, 2009 10:14 pm
Location: Boston, MA

Re: Text management in a database?

Post by skywalk »

Yeah, a big topic you touch on with so little words.
SQLite out of the box, does not support encryption. There is the paid SEE lib from the author for $2000.
If you download and install DB Browser for SQLite, it offers 2 exe's. One is "C:\Program Files\DB Browser for SQLite\DB Browser for SQLCipher.exe".
It supports encryption via "C:\Program Files\DB Browser for SQLite\sqlcipher.dll", an open source lib.
You can use PB's new UseSQLiteDatabase() command:

Code: Select all

CompilerIf #SQLITE_USE_DLL  ;-! USE sqlite3.dll
  #SQLITE_DLL_FNPATH$ = "C:\Program Files\DB Browser for SQLite\sqlcipher.dll"
  UseSQLiteDatabase(#SQLITE_DLL_FNPATH$)
...
I would install DB Browser and start prototyping your tables and queries.
Then codify them in PB with the verified SQL.
A lot left out, but there are many examples in the forum for SQLite use.
The nice thing about standards is there are so many to choose from. ~ Andrew Tanenbaum
Post Reply