I'm connecting my Firebird database with FireDAC (migrating from FIBPlus and using XE8 update 1). I'm using trusted authentication (OSAutenth=True). I need to read the list of tables within the database. I'm using the TFDConnection.GetTableNames and it works well with standard autenthication (username+password) but I'm not capable to get it work using trusted authentication. Maybe I'm doing something wrong or I'm using the wrong method to to get that kind of info. This is what I'm doing:
var
oDef : IFDStanConnectionDef;
oPars: TFDPhysFBConnectionDefParams;
begin
oDef:=FDManager.ConnectionDefs.AddConnectionDef;
oDef.Name:='MyFirebird';
oPars:=TFDPhysFBConnectionDefParams(oDef.Params);
oPars.DriverID:='FB';
oPars.Protocol:=ipTCPIP;
oPars.Server:=edServer.Text;
oPars.SQLDialect:=3;
oPars.Database:=edDataBase.Text;
oPars.OSAuthent:=(edPassword.Text='');
oPars.UserName:='SYSDBA';
oPars.Password:=edPassword.Text;
oPars.RoleName:=edRole.Text;
oPars.OpenMode:=omOpen;
FDPhysFBDriverLink1.Embedded:=False;
FDPhysFBDriverLink1.VendorLib:='c:\MyProgram\fbclient.dll';
FDConnection1.ConnectionDefName:='MyFirebird';
FDConnection1.Connected:=TRUE;
FDConnection1.GetTableNames('','','',Memo1.Lines,[osMy],[tkTable]); '<--- doesn't works with os authentication
FDQuery1.SQL.Text:='select * from MYTABLE';
FDQuery1.Active:=TRUE; '<--- works fine in both kind of authentication
The FIBPlus TpFIBDatabase.GetTableNames that I am going to substitute works fine with both kind of authentications.
Any idea?