

If Not Exist(MGlobal.sDataPath) Then FMain.CheckDirIntegrity()

Public sDataPath As String = User.Home &/ sBaseDir &/ sAppDir &/ sDataDir Public sConfigPath As String = User.Home &/ sBaseDir &/ sAppDir &/ sConfigDir Public sAppDirPath As String = User.Home &/ sBaseDir &/ sAppDir Public sConfigFilename As String = sAppDir & ".conf" Public sAppDir As String = Application.Name Public sBaseDir As String = ".WhiteIslandSoftware" When creating a new db app, I just copy these 2 files into the new app and make a few changes. (This is from my event reminder app.) If I need to have the db in a NFS location, I can easily change the sBaseDir string variable and drop the "User.Home &/" from the xxxPath string variables. This is how I set up my sqlite databases. Host = /path/to/shared/directory/Gambas/my-tv" When putting the db file in a directory outside of the user's home directory (such as an NFS shared directory), omit "User.Home" and add an absolute path with a beginning slash ("/"). When putting the db file in a user's home directory, set the ".host" path by using "User.Home" (instead of hard coding the path). When setting the ".host" path, no need to use a trailing slash ("/"). That means, it did NOT work with this path: wslUbuntuhomeiamgrootdevdev. I copied the database to my desktop and the db opened fine. There used to be a blurb on this in the wiki, but it looks like db access has been rewritten in the wiki for both SQLite and mySQL. I tried to open a SQLite database inside of a Windows Subsystem for Linux 2 installation (Ubuntu) and nothing happened.
#Cant drag db.sqlite3 to db browser for sqlite code
If you think of ".Host" as a " location" and not just as a path, machine name, or IP address, and use a variable to hold that " location", you should be able to craft your db access code to be swap-able between mySQL and SQLite with minimum effort. I haven't created a mySQL db in about 10 years since SQLite is all I've needed for my apps.
