ecto

7 Articles
A wizard catching an elephant that flies through the air, forest landscape in the background, digital art

Test an external, read-only Repository in Phoenix

When your application connects to an external database in read-only mode, it becomes difficult to write proper tests for it. This post explains how to set up a simulated external database locally to make testing becomes easy again.

a young wizard apprentice looking at a book with a magnifying glass in an old library, digital art

Unaccented Name Search with Postgres and Ecto

Postgres does not support searching for names with special characters by default. Here is how to fix it.

A librarian frantically searching through a catalog of books

The Complete Guide to Full-text Search with Postgres and Ecto

A detailed deep-dive into efficient full-text search for multiple languages, result ranking, tsvectors and tsqueries, search modifiers, and so much more.

A librarian searching through a thick book

Efficient Name Search with Postgres and Ecto

Search through millions of strings efficiently using indexed ILIKE or SIMILARITY queries.

Two clock with frustrated faces pointing a finger at each other

Prevent overlapping time ranges with Ecto and Postgres

Block overlapping appointments efficiently in your database using exclusion constraints and don't worry about double-bookings ever again!

A panda reserving a sunbed at a pool by laying down a towel

Optimize Ecto's insert_all with Placeholders

Write more efficient bulk insert queries and avoid sending duplicate data by using placeholders.

A panda carrying a pile of books through a dusty library

The complete guide to Upserts with Ecto

Implement insert-or-update functionality for your schemas directly with Ecto's on_conflict option.