Skip to content

Linux Database Location #689

Answered by alextekartik
furkantiv asked this question in Q&A
Discussion options

You must be logged in to vote
var factory = databaseFactoryFfi;
print(await factory.getDatabasesPath());

should give you something like:

<current_dir>/.dart_tool/sqflite_common_ffi/databases

which is just a placeholder location. The recommendation for Linux (and Desktop in General) is to use path_provider package to find the best location (I'm not aware of any recommendation on Linux but there might be common locations) and use an absolute path when opening a database.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@furkantiv
Comment options

Answer selected by furkantiv
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants