[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gambas-bugtracker] Bug #2986: sqlite connection "Database does not exist"


http://gambaswiki.org/bugtracker/edit?object=BUG.2986&from=L21haW4-

Comment #17 by Benoît MINISINI:

> Hi Benoît
> I thought that the screen video will clearly explain the actual problem.
> Bruce and you are assuming that the data base should be copied to somewhere to get it writable or to being able to open it.
> Simply forget this. The data base will stay in the root directory and will not be copied to somewhere because 
> a. a database also can be opened if it resides in the project directory

This is where I disagree: every file in the project directory is not a file anymore at runtime, but a piece of the executable archive that can be see as file only by the Gambas interpreter, or by some components provided they use some interpreter API that the sqlite driver cannot use.

In other words, there is no way for sqlite to be able to see a sqlite database file located inside a project, except at design time.

> b. the programmer may want to use the data base in read-only mode    

The user opening the database in read-only mode is not a guarantee that sqlite will not write in the file. You can't know.

> c. the programmer wants to use the connection object established in the IDE-directory

Consequently, it must not be possible to create a connection on a file located in the project directory.


----[ Gambas bugtracker-list is hosted by https://www.hostsharing.net ]----