The getSelect() method is actually a method leaking from jOOQ's internal API. It happens to be useful in these cases.
Unfortunately, jOOQ's model API (SelectQuery) doesn't expose its component QueryParts yet. This feature is on the roadmap for jOOQ 4.0: https://github.com/jOOQ/jOOQ/issues/2198 In other words, once constructed, it is hard to introspect a Query object short of using: - Reflection - A custom RenderContext and/or BindContext - String parsing from generated SQL Cheers, Lukas 2013/7/22 Вячеслав Бойко <[email protected]> > Thank you. This code helps to gain all the fields in the query: > > DSLContext create = DSL.using(conn, SQLDialect.POSTGRES); > SelectSelectStep<Record> selection = create.select(); > SelectJoinStep<Record> selectionFrom = selection.from(Servers.SERVERS); > List<Field<?>> fieldsList = selectionFrom.getSelect(); > System.out.println("FIELDS: " + fieldsList.toString()); > for (Field<?> f : fieldsList) { > System.out.println("field: " + f.toString()); > } > > > But now how can I retreive table info with indexes names and primary key > name? > > -- > You received this message because you are subscribed to the Google Groups > "jOOQ User Group" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- You received this message because you are subscribed to the Google Groups "jOOQ User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
