Page 2 of 2

Re: Use SQLite with SpiderBasic

Posted: Wed Sep 20, 2017 6:15 pm
by IdeasVacuum
The possibility of SB using SQLite is really good (I think perhaps Fred has pencilled it for the next release?).

What is very important for those of us writing apps for Android/iOS is that the db file can be saved locally and never requires an Internet connection.

Re: Use SQLite with SpiderBasic

Posted: Fri Feb 19, 2021 8:38 am
by Dirk Geppert
Hi folks,

is there any news on this? Will SQLiIte be implemented directly in SB?

Unfortunately, the example no longer works. Presumably this is the current link to SQL.js:
https://cdnjs.cloudflare.com/ajax/libs/ ... sql.min.js
But UseSQLiteDatabase() failed..

Re: Use SQLite with SpiderBasic

Posted: Mon Feb 22, 2021 10:31 am
by the.weavster
Dirk Geppert wrote:But UseSQLiteDatabase() failed..
The UseSQLiteDatabase() command doesn't exist in SpiderBasic but SQLite does work. Look at the example in the manual.

Re: Use SQLite with SpiderBasic

Posted: Mon Feb 22, 2021 9:34 pm
by IdeasVacuum
the.weavster wrote:
Dirk Geppert wrote:But UseSQLiteDatabase() failed..
The UseSQLiteDatabase() command doesn't exist in SpiderBasic but SQLite does work. Look at the example in the manual.
The manual?

Re: Use SQLite with SpiderBasic

Posted: Mon Feb 22, 2021 10:24 pm
by Paul
IdeasVacuum wrote: The manual?
The "Help File"... under "Database"

Re: Use SQLite with SpiderBasic

Posted: Tue Feb 23, 2021 1:32 am
by IdeasVacuum
Oh right, sorry, my misunderstanding.

Looking at the examples, I'm not sure the saving of the DB file on Android is valid. Google recently added a lot of security measures, Android 10 and up basically sandbox Apps (similar to Apple IOS I think). Now, there are only two directories an App can use. The App directory (App Private Directory) itself which has read-only resources and the App Specific Directory which is read-write and where the DB file should be.

Re: Use SQLite with SpiderBasic

Posted: Tue Feb 23, 2021 7:41 am
by Dirk Geppert
Thx IdeasVacuum, for that hint. The Sqlite example from the help works.
It's also interesting that the stored text in the database is not visible in the browser debugger in the web storage.
There is only one array to see..

Re: Use SQLite with SpiderBasic

Posted: Tue Feb 23, 2021 7:51 am
by Peter
Dirk Geppert wrote:There is only one array to see..
... which however can be converted relatively easily.

So I would not store state secrets in it. ;)