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

[Gambas-bugtracker] Bug #2915: Unable to locate database in gb.db2


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

Comment #1 by Benoît MINISINI:

You are actually using an unwanted side-effect of using relative path in the sqlite connection, that allows you to open a database file located in the current project.

But this is normally forbidden, as files inside the current project are supposed to be read-only.

If you use the 'gb.db' component, then create an executable of the project, but not inside the project directory (for example in your home directory), and finally run it, the database relative path will not be found, and you will get an error.

So for me it's a bug fix, even if it breaks backward-compatibility.

A possible alternative solution would be to detect that case, and make a copy of the database file in a temporary directory so that it can be opened.

What do you think?

Benoît MINISINI changed the state of the bug to: NeedsInfo.


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