ADO如何记录SQL日志
procedure TfrmDM.ADOConnection1WillExecute(Connection: TADOConnection; var CommandText: WideString; var CursorType: TCursorType; var LockType: TADOLockType; var CommandType: TCommandType; var ExecuteOptions: TExecuteOptions; var EventStatus: TEventStatus; const Command: _Command; const Recordset: _Recordset);
begin
// write sql log
if sqldebug then
Log.WriteLog('CommandText:' + CommandText);
end;