EfueliteSolutionsDbLogger 1.0.3

dotnet add package EfueliteSolutionsDbLogger --version 1.0.3
NuGet\Install-Package EfueliteSolutionsDbLogger -Version 1.0.3
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="EfueliteSolutionsDbLogger" Version="1.0.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add EfueliteSolutionsDbLogger --version 1.0.3
#r "nuget: EfueliteSolutionsDbLogger, 1.0.3"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install EfueliteSolutionsDbLogger as a Cake Addin
#addin nuget:?package=EfueliteSolutionsDbLogger&version=1.0.3

// Install EfueliteSolutionsDbLogger as a Cake Tool
#tool nuget:?package=EfueliteSolutionsDbLogger&version=1.0.3

Efuelite Solutions Database Logger

This is a simple to implement but lightweight and highly efficient package used to log informations from .Net applications to Database

Usage


  1. In class where Efuelite Db Logger is to be used, just import the name space EfueliteSolutionsDbLogger.

  2. To log an information, call string status = DbLogger.WriteLog(string DBConnectionString, string Log); This function returns a string status telling the outcome of its operation.

    Parameters:

    • Supply connection string to the database(mssql) where it will log information.
    • The information to log in string format.
  3. To read/search all information from logs, just call var obj = DbLogger.SearchLog(string DBConnectionString, string SearchCrit = "", string Sort = "0", int PageNumber = 1, int PageSize = 10, DateTime? StartDate = null, DateTime? EndDate = null);

    Parameters:

    • DBConnectionString: Database connection string
    • SearchCrit: Optional: phrase to search for when retrieving logs
    • Sort: Optional: default value is "0" which is descending order by logdate
    • PageNumber: Optional: default value is 1, meaning search returns records from page 1
    • PageSize: Optional: default value is 10, menaing search returns 10 records per page
    • StartDate: Optional: default value is todays date. If there is no log for today, then no result is returned
    • EndDate: Optional: default value is todays date. If there is no log for today, then no result is returned
    • Returns a model list with log properties such as Total, Status, LogId, LogDescription, LogDate in UTC format.
  4. To delete logs, just call string status = DbLogger.DeleteLog(string DBConnectionString, string LogId);

    This function returns a string status telling the outcome of its operation. Parameters:

    • Supply connection string to the database(mssql).
    • Supply the LogID of the Log to be deleted.
Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.3 94 2/4/2024
1.0.2 72 2/4/2024
1.0.1 156 3/8/2023

A simple lightweight logger