procedure TfrmMain.Button1Click(Sender: TObject);
var
SQLConnection : TSQLConnection;
SQLQuery : TSQLQuery;
begin
SQLConnection := TSQLConnection.Create(Self);
SQLConnection.ConnectionName := '
SQLCon';
SQLConnection.DriverName := '
MYSQL';
SQLConnection.GetDriverFunc := '
getSQLDriverMYSQL';
SQLConnection.LibraryName := '
dbxmys30.dll';
SQLConnection.VendorLib := '
LIBMYSQL.dll';
SQLConnection.Params.Values['
BlobSize'] := '
-1';
SQLConnection.Params.Values['
Database'] := '
Kunden';
SQLConnection.Params.Values['
ErrorRessourceFile'] := '
';
SQLConnection.Params.Values['
HostName'] := '
localhost';
SQLConnection.Params.Values['
LocaleCode'] := '
0000';
SQLConnection.Params.Values['
User_Name'] := '
root';
SQLConnection.Params.Values['
Password'] := '
password';
SQLConnection.Params.Values['
Compressed'] := '
False';
SQLConnection.Params.Values['
Encrypted'] := '
False';
SQLConnection.LoginPrompt := False;
SQLConnection.ParamsLoaded := True;
SQLConnection.KeepConnection := True;
SQLConnection.Connected := True;
SQLConnection.Open;
Memo1.Lines.Add('
Verbindung hergestellt ...!');
SQLQuery := TSQLQuery.Create(Self);
SQLQuery.SQLConnection := SQLConnection;
SQLQuery.SQL.Text := '
Select * from Kunde';
SQLQuery.Active := True;
SQLConnection.Close;
SQLConnection.Free;
Memo1.Lines.Add('
Verbindung beendet ...!');
end;