VALUES in Esqueleto / Persistent - Haskell

Welcome to the Functional Programming Zulip Chat Archive. You can join the chat here.

Jonathan Lorimer

does anyone know how to construct a table from a list of values in esqueleto?

I have [(MyID1, MyID2)] and I want to treat this as a 'table' and join on it
I figure I probably need to use the new CTE with function

This would effectively be the same as doing this:

WITH foo (col1, col2, col3) AS (
    SELECT * FROM (
        VALUES
            (1, 2, 3),
            (2, 3, 4)
        ) AS TMP
    )

SELECT * FROM foo