BlueCollar.SQLiteRepository.DeleteHistory C# (CSharp) Метод

DeleteHistory() публичный Метод

Deletes history older than the given date.
public DeleteHistory ( string applicationName, System.DateTime olderThan, IDbTransaction transaction ) : void
applicationName string The name of the application to delete data for.
olderThan System.DateTime The date to delete history older than.
transaction IDbTransaction The transaction to use, if applicable.
Результат void
        public void DeleteHistory(string applicationName, DateTime olderThan, IDbTransaction transaction)
        {
            const string Sql =
            @"DELETE FROM [BlueCollarHistory]
            WHERE
            [ApplicationName] = @ApplicationName
            AND [QueuedOn] < @OlderThan;";

            this.connection.Execute(
                Sql,
                new { ApplicationName = @applicationName, OlderThan = olderThan },
                transaction,
                null,
                null);
        }