Thread
#exposed
    e

    Edouard Goossens

    3 years ago
    Hi everyone, I’m pretty new to exposed, and I’m wondering if there’s a way to do something equivalent to:
    SELECT field1, field2, field2-field1 AS diff FROM table
    using DAO. Thanks!
    tapac

    tapac

    3 years ago
    val diff = val columns = Expression.build { Table.field2 - Table.field1 }.alias("diff")
    Table.slice(Table.field1, Table.field2, diff).selectAll()
    e

    Edouard Goossens

    3 years ago
    Thanks!