Simplifying Sql.schema.* Utilities Usage

Which pattern we can use to simplify the usage of Sql.schema.* utilities? I always find myself doing something like this:
// This to define the query
const myQuery = Effect.map(Connection, (sql) =>
    Sql.schema.single({
        Request: Schema.Unknown,
        Result: Schema.Unknown,
        execute: () => sql`SELECT 1`,
    }),
);

// This to execute it
const result = yield* Effect.flatMap(myQuery, (query) => query());


Can this be simplified?
Was this page helpful?