Joining two SQL cells (or csvs)

I really like the SQL cells in notebooks and much prefer to wrangle data in SQL over JS.

  • I have a CSV of opportunities and another CSV of accounts. Is there a way to join them together in a SQL?
  • If instead, I want to transform opportunities into opportunities_clean in a cell and then join it to a transformed accounts_clean in a new cell, how would I do that?

You can create an in-memory DuckDB database with multiple tables: Database clients | Observable documentation

The cell then becomes available as data source for SQL and Data Table cells.

Yes that did the trick. Thanks so much.