Ok I found a hack. I created own TMyConnection = class(TSQLite3Connection)
so I have access to protected execsql which don't check transaction:

type

  { TMyConnection }

  TMyConnection = class(TSQLite3Connection)
  public
    procedure ExecSQLNoTrans(const ASql: String);
  end;

implementation

procedure TMyConnection.ExecSQLNoTrans(const ASql: String);
begin
  execsql(ASql);
end;

And now I can attach my second database by calling:

    DBConnection.ExecSQLNoTrans('attach database
'+QuotedStr(GetConfigDir+'second.db')+' as mydb2');

Each system can be broken ;)

Regards
--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to