Provides native PostgreSQL trigram similarity search for core billing objects.
Utilizes the pg_trgm extension and specific GIN indices for fast,
fuzzy text matching without full table scans. Results are ranked by
similarity (GREATEST(similarity(...)) for multi-column searches).
Summary
Functions
Searches Accrue.Billing.Customer by email or name.
Searches Accrue.Billing.Invoice by processor_id or number.
Searches Accrue.Billing.Subscription by processor_id.
Functions
@spec search_customers(Ecto.Queryable.t(), String.t()) :: Ecto.Query.t()
Searches Accrue.Billing.Customer by email or name.
@spec search_invoices(Ecto.Queryable.t(), String.t()) :: Ecto.Query.t()
Searches Accrue.Billing.Invoice by processor_id or number.
@spec search_subscriptions(Ecto.Queryable.t(), String.t()) :: Ecto.Query.t()
Searches Accrue.Billing.Subscription by processor_id.