Discussion of open issues, suggestions and bugs regarding LiteDAC (SQLite Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
- Posts: 11
- Joined: Wed 21 May 2014 17:07
I'm getting error when I try to use TCustomDAConnection.GetDatabaseNames in Firemonkey.
Code: Select all
LTS := DBM.CRTT.Database;
LTS := leftstr(LTS,length(LTS)-3)+' - Data.db';
DBM.LiteSQL1.SQL.Add('ATTACH DATABASE "'+LTS+'" as "LTS";');
When using the GetDatabaseNames I get an "Unsupported metadata kind", however the GetTableNames does work and returns the number of tables in the Main db.
I didn't find online documentation, can you provide example of proper use of GetDatabaseNames?
- Devart Team
- Posts: 866
- Joined: Mon 06 Jul 2015 11:34
It's true, this functionality is not implemented in LiteDAC, the message you receive is an evidence of this. This is due to specificity of SQLite itself. The GetDatabaseNames method is designed to obtain a list of available databases to which the used server allows you to connect. SQLite only allows getting a list of databases connected to the current connection. To get the information you need, in LiteDAC instead of the GetDatabaseNames method, you can use the following query: