PgConnectOptions connectOptions = new PgConnectOptions() (1)
.setPort(5432).setHost("the-host")
.setDatabase("the-db").setUser("user").setPassword("secret");
PoolOptions poolOptions = new PoolOptions().setMaxSize(5); (2)
PgPool pgPool = PgPool.pool(vertx, connectOptions, poolOptions); (3)
Jooqx jooqx = Jooqx.builder() (4)
.setVertx(vertx)
.setDSL(DSL.using(SQLDialect.POSTGRES)) (5)
.setSqlClient(pgPool)
.build();
jooqx.fetchOne(dsl -> dsl.selectFrom(Tables.AUTHORS) (6)
.where(Tables.AUTHORS.NAME.eq("zero88")))
.onSuccess(result -> { (7)
AuthorsRecord rec = result; (8)
System.out.println(rec.getName());
System.out.println(rec.getCountry());
}).onFailure(System.err::println); (9)