MatinDeWet.Searchable.PostgreSQL 1.0.0

dotnet add package MatinDeWet.Searchable.PostgreSQL --version 1.0.0
                    
NuGet\Install-Package MatinDeWet.Searchable.PostgreSQL -Version 1.0.0
                    
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="MatinDeWet.Searchable.PostgreSQL" Version="1.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="MatinDeWet.Searchable.PostgreSQL" Version="1.0.0" />
                    
Directory.Packages.props
<PackageReference Include="MatinDeWet.Searchable.PostgreSQL" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add MatinDeWet.Searchable.PostgreSQL --version 1.0.0
                    
#r "nuget: MatinDeWet.Searchable.PostgreSQL, 1.0.0"
                    
#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.
#:package MatinDeWet.Searchable.PostgreSQL@1.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=MatinDeWet.Searchable.PostgreSQL&version=1.0.0
                    
Install as a Cake Addin
#tool nuget:?package=MatinDeWet.Searchable.PostgreSQL&version=1.0.0
                    
Install as a Cake Tool

Searchable.PostgreSQL

NuGet Version CI Status Publish Status

PostgreSQL-specific dynamic search helpers for Entity Framework Core.

This package provides a focused API for building PostgreSQL-backed search filters over IQueryable<T> using expression-based property selectors for both full-text search and ILIKE pattern matching.

Package

dotnet add package MatinDeWet.Searchable.PostgreSQL

What It Does

  • Builds dynamic search predicates from a request object.
  • Supports PostgreSQL full-text search via tsvector + plainto_tsquery.
  • Supports ILIKE modes: Contains, StartsWith, EndsWith, and Exact.
  • Escapes wildcard characters for safe ILIKE usage.
  • Supports searching a single property or multiple properties with OR / AND logic.

Usages

1. Full-text search on a tsvector property

Use this when your entity has a mapped PostgreSQL tsvector property and you want to point directly to that property with an expression selector.

using NpgsqlTypes;
using Searchable.PostgreSQL;
using Searchable.PostgreSQL.Contracts;

IQueryable<Person> query = dbContext.People;
ISearchableRequest request = new SearchableRequest("john manager");

query = query.FullTextSearch(
    request,
    person => person.SearchVector,
    language: "english");

The selector expression is translated server-side, so you get the same simple property-targeting style as the single-property ILIKE API.

2. ILIKE search on a single property

using Searchable.PostgreSQL;
using Searchable.PostgreSQL.Enums;

query = query.ILikeSearch(
    request,
    person => person.Email!,
    ILikeMatchModeEnum.Contains);

3. ILIKE search across multiple properties

query = query.ILikeSearch(
    request,
    [person => person.FirstName!, person => person.LastName!, person => person.Email!],
    ILikeMatchModeEnum.StartsWith,
    useOrLogic: true);

4. Match modes

ILikeMatchModeEnum controls the generated PostgreSQL pattern:

  • Contains: %term%
  • StartsWith: term%
  • EndsWith: %term
  • Exact: term

API Surface

  • Searchable.PostgreSQL.SearchableExtensions
  • Searchable.PostgreSQL.Contracts.ISearchableRequest
  • Searchable.PostgreSQL.Enums.ILikeMatchModeEnum

The package uses the GPL-3.0-only license.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  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. 
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.0 166 6/13/2026