Loq 0.1.79
dotnet add package Loq --version 0.1.79
NuGet\Install-Package Loq -Version 0.1.79
<PackageReference Include="Loq" Version="0.1.79" />
<PackageVersion Include="Loq" Version="0.1.79" />
<PackageReference Include="Loq" />
paket add Loq --version 0.1.79
#r "nuget: Loq, 0.1.79"
#:package Loq@0.1.79
#addin nuget:?package=Loq&version=0.1.79
#tool nuget:?package=Loq&version=0.1.79
Loq
Modern .NET API for loq — a cross-platform reimplementation of Microsoft Log Parser 2.2 in Rust.
If you want a drop-in replacement for the classic MSUtil.LogQuery COM interface, use Loq.Classic instead. Loq is for new code that wants idiomatic .NET ergonomics: strongly-typed results, IEnumerable<T>, DataTable, and bulk JSON transfer for performance.
Install
dotnet add package Loq
The package transitively pulls in Loq.Native, which ships native binaries for win-x64 and linux-x64.
Quick start
using Loq;
// Strongly-typed results
public record Request(string c_ip, int sc_status, string cs_uri_stem);
foreach (var req in LogEngine.Query<Request>(
@"SELECT c-ip, sc-status, cs-uri-stem
FROM 'C:\logs\W3SVC1\*.log'
WHERE sc-status >= 400"))
{
Console.WriteLine($"{req.c_ip} → {req.sc_status} {req.cs_uri_stem}");
}
API surface
// Typed projection — properties are matched against output columns by name (case-insensitive).
IEnumerable<T> LogEngine.Query<T>(string sql)
IEnumerable<T> LogEngine.Query<T>(string sql, string? inputFormat = null, int maxRows = 0)
// Untyped — each row as a Dictionary<string, object?>.
IEnumerable<Dictionary<string, object?>> LogEngine.Query(string sql)
IEnumerable<Dictionary<string, object?>> LogEngine.Query(string sql, string? inputFormat = null, int maxRows = 0)
// Full result with metadata (column types, total row count).
QueryResult LogEngine.Execute(string sql)
// Count-only — skips materializing rows; faster for `SELECT COUNT(*)`-style queries.
long LogEngine.Count(string sql)
// Schema introspection without executing.
SchemaInfo LogEngine.GetSchema(string sql)
// One-line conversion to System.Data.DataTable.
DataTable LogEngine.ToDataTable(string sql)
SQL syntax
Same as MS Log Parser 2.2 — see the LP22 syntax reference for SELECT/FROM/WHERE/GROUP BY/ORDER BY/USING/INTO, the 100+ built-in functions (SUBSTR, QUANTIZE, EXTRACT_TOKEN, TO_TIMESTAMP, HASHMD5, etc.), and LP22 features like comma-separated multi-source FROM (FROM 'a','b','c'), wildcard FROM paths (case-insensitive on every platform), and INTO for file/chart output.
Supported input formats include CSV, TSV, W3C, IIS native + binary, NCSA / Apache / Nginx, JSON / NDJSON, XML, EVTX, REG, PCAP, syslog, fixed-width text, S3, Parquet, plus filesystem and ETW (Windows). Output formats include CSV, TSV, JSON, XML, W3C, IIS, DATAGRID, SQLite, SQL Server, MySQL / Aurora MySQL, PostgreSQL, ODBC (Windows), syslog, CloudWatch, NAT (native binary), Parquet, charts (PNG / SVG), and templates.
Aurora MySQL is wire-compatible with MySQL — connect via standard mysql://user:pass@aurora-writer-endpoint/db?ssl-mode=REQUIRED URL. See docs/output-formats/mysql.md for cluster-endpoint, TLS, and batch-sizing guidance.
Performance
Bulk JSON transfer between the .NET layer and the native engine — the native library does all of the parsing, filtering, grouping, and projection in Rust, then ships back a single JSON payload. For typical loq workloads (millions of log rows) this is significantly faster than row-by-row iteration through P/Invoke.
If you want streaming row-by-row for very large result sets, drop down to Loq.Classic's LogRecordSet cursor API.
Source / issues
- Source: https://github.com/chaynes81-ux/loq
- Releases & docs: https://chaynes81-ux.github.io/loq-releases/
- Issues: file at the GitHub repo above.
License
MIT.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- Loq.Native (>= 0.1.79)
- System.Text.Json (>= 8.0.5)
-
net8.0
- Loq.Native (>= 0.1.79)
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 |
|---|---|---|
| 0.1.79 | 137 | 8/5/2026 |
| 0.1.78 | 123 | 8/4/2026 |
| 0.1.77 | 122 | 7/26/2026 |
| 0.1.76 | 124 | 7/23/2026 |
| 0.1.75 | 127 | 7/8/2026 |
| 0.1.74 | 127 | 7/8/2026 |
| 0.1.73 | 128 | 6/24/2026 |
| 0.1.72 | 139 | 6/24/2026 |
| 0.1.71 | 141 | 6/13/2026 |
| 0.1.70 | 126 | 6/12/2026 |
| 0.1.69 | 120 | 6/11/2026 |
| 0.1.68 | 130 | 6/10/2026 |
| 0.1.67 | 120 | 6/10/2026 |
| 0.1.66 | 116 | 6/9/2026 |
| 0.1.65 | 127 | 6/9/2026 |
| 0.1.64 | 128 | 6/1/2026 |
| 0.1.63 | 138 | 5/8/2026 |
| 0.1.62 | 117 | 5/5/2026 |
| 0.1.61 | 117 | 5/5/2026 |
| 0.1.60 | 115 | 5/5/2026 |