samoloth
Hi,
since my project will require some analytics, I’ve decided to use Postgres + DuckDB via pg_duckdb extension. I’ve spinned up an official pgduckdb container, set up credentials, run mix ash.reset, added pg_duckdb to installed_extensions/0 and finally run mix ash.codegen install_pg_duckdb + mix ash.migrate, but I end up with:
Getting extensions in current project...
Running migration for AshPostgres.DataLayer...
09:31:07.612 [info] == Running 20251218083057 MyApp.Repo.Migrations.InstallPgDuckdbExtensions1.up/0 forward
09:31:07.619 [info] execute "CREATE EXTENSION IF NOT EXISTS \"pg_duckdb\""
09:31:07.670 [info] == Migrated 20251218083057 in 0.0s
** (Postgrex.Error) ERROR 42P01 (undefined_table) relation "schema_migrations" does not exist
query: INSERT INTO "schema_migrations" ("version","inserted_at") VALUES ($1,$2)
(ecto_sql 3.13.3) lib/ecto/adapters/sql.ex:1108: Ecto.Adapters.SQL.raise_sql_call_error/1
(ecto 3.13.5) lib/ecto/repo/schema.ex:1000: Ecto.Repo.Schema.apply/4
(ecto 3.13.5) lib/ecto/repo/schema.ex:500: anonymous fn/15 in Ecto.Repo.Schema.do_insert/4
(my_app 0.1.0) lib/my_app/repo.ex:2: MyApp.Repo.insert/2
(ecto_sql 3.13.3) lib/ecto/migrator.ex:338: anonymous fn/6 in Ecto.Migrator.async_migrate_maybe_in_transaction/7
(my_app 0.1.0) lib/my_app/repo.ex:2: anonymous fn/1 in MyApp.Repo."transaction (overridable 1)"/2
(ecto 3.13.5) lib/ecto/repo/transaction.ex:11: anonymous fn/3 in Ecto.Repo.Transaction.transact/4
(ecto_sql 3.13.3) lib/ecto/adapters/sql.ex:1468: anonymous fn/3 in Ecto.Adapters.SQL.checkout_or_transaction/4
Here are some additional logs:
$ psql -U duck
psql (18.1 (Debian 18.1-1.pgdg12+2))
Type "help" for help.
duck=# \dx
List of installed extensions
Name | Version | Default version | Schema | Description
-----------+---------+-----------------+------------+------------------------------
pg_duckdb | 1.1.0 | 1.1.0 | public | DuckDB Embedded in Postgres
plpgsql | 1.0 | 1.0 | pg_catalog | PL/pgSQL procedural language
(2 rows)
duck=# \c my_app_dev
You are now connected to database "my_app_dev" as user "duck".
my_app_dev=# \dx
List of installed extensions
Name | Version | Default version | Schema | Description
---------+---------+-----------------+------------+------------------------------
plpgsql | 1.0 | 1.0 | pg_catalog | PL/pgSQL procedural language
(1 row)
my_app_dev=# SELECT * FROM schema_migrations;
version | inserted_at
----------------+---------------------
20251210094714 | 2025-12-18 08:28:00
(1 row)
As you can see, schema_migrations table exists.
Trending in Questions
Hello!
Suppose you are building workflow (order / task / payment) processing system with the following requirements:
Each workflow con...
New
Hi all,
I’m working on a Phoenix project where I need to make external HTTP requests and I’m trying to choose between Req and HTTPoison....
New
How do I tell Hologram not to escape HTML when substituting into templates?
{Textile.render(@product.long_description)}
escapes the HTM...
New
I’d like to create a file with 600 permissions (rw-------), but there’s a race condition if I create it and then change the permissions. ...
New
Hi,
we run different LLM models across a cluster, with each node loading a configurable subset. Model-specific queues let nodes consume ...
New
When I use Mix.install with a git dependency, using git@github.com:... how do I change the SSH identity used?
I’ve got two Github accoun...
New
Hello all. I have a question as to best practices for code organization when implementing a liveview with a lot of responsibilities.
Sup...
New
Other Trending Topics
Hey there,
I haven’t seen a list of useful Elixir specific skills for the popular AI tools yet so I’m starting one here with my first.
...
New
Hi everyone :waving_hand:
I wanted to share something I’ve been building — NowBlind, a random chat app designed to help people discover ...
New
I fully migrated to my own harness from Anthropic/Gemini and I think it’s time to share it. Welcome DSH, the DeepSeek Harness, fully writ...
New
Hey. Is there anyone here who creates agents in their apps? Not talking about using agents, but creating them. I’m finding it pretty diff...
New
(I just needed to vent somewhere and LinkedIn is full of hope, or hype, I’m not sure which exactly)
AI dream has many faces, but general...
New
Localize is the next generation localisation library for Elixir. Think of it as ex_cldr version 3.0. The first version will be released ...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #code-sync
- #discussion
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #ai
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #elixirconf-us
- #blog-post
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #elixirconf-eu
- #processes
- #security
- #api
- #forms
- #performance










Showing Posts 1 to 2- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
samoloth
Ok, I works with ddl transaction disabled. Question is whether it should be disabled by default when it comes to extensions?
zachdaniel
Hmm…it could yes? It must be a restriction of duck db though because we don’t have that issue with Postgres. Makes me wonder if Postgres can actually transactionally install an extension. Feels like probably not.
With that said we define functions etc. which we’d want to be transactional.