Hi!
I have just downloaded SQLite Administrator. It looks great. However, it seems to be unable to open databases with Swedish characters (ÅÄÖ, åäö) in the path or filename...
Is this easy to fix?
When trying to open such a DB, SQLite Admin seems to create a new, empty DB with the same name except all Swedish characters are gone...
Regards
Carl Gustafsson
Swedish characters (ÅÄÖ) in path
Moderators: gto, EgonHugeist, Orbmu2k
At sqlite2 databases i dont see any problems ...
But at Sqlite3 Databases iam also unable to create a database with these chars.
I got:
this bug seem so be related by zeoslib
But at Sqlite3 Databases iam also unable to create a database with these chars.
I got:
Code: Select all
library routine called out of sequence
It is related to the Sqlite Version, because since 3.2.5 utf8 is used internally. I had the same problem with german Umlauts in the path. I changed the Open function in ZPlainSqlite3Driver.pas to use utf8 for versions > 3.2.5. Now it works.
function TZSQLite3PlainDriver.Open(const filename: PChar; mode: Integer;
var errmsg: PChar): Psqlite;
var
Result0: Psqlite;
Version: string;
FileNameString: String;
begin
Version := LibVersion;
Result0:= nil;
FileNameString := filename;
if (Version > '3.2.5') then
ZPlainSqLite3.sqlite_open(PAnsiChar(AnsiToUTF8(FileNameString)), Result0)
else
ZPlainSqLite3.sqlite_open(filename, Result0);
Result := Result0;
end;
function TZSQLite3PlainDriver.Open(const filename: PChar; mode: Integer;
var errmsg: PChar): Psqlite;
var
Result0: Psqlite;
Version: string;
FileNameString: String;
begin
Version := LibVersion;
Result0:= nil;
FileNameString := filename;
if (Version > '3.2.5') then
ZPlainSqLite3.sqlite_open(PAnsiChar(AnsiToUTF8(FileNameString)), Result0)
else
ZPlainSqLite3.sqlite_open(filename, Result0);
Result := Result0;
end;
Why not:
??
Code: Select all
function TZSQLite3PlainDriver.Open(const filename: PChar; mode: Integer;
var errmsg: PChar): Psqlite;
var
Result0: Psqlite;
begin
Result0:= nil;
if (LibVersion > '3.2.5') then
ZPlainSqLite3.sqlite_open(PAnsiChar(AnsiToUTF8(FileName)), Result0)
else
ZPlainSqLite3.sqlite_open(filename, Result0);
Result := Result0;
end;