Get Table schema using jooq

Viewed 96

Currently I am working on a jooq project where I need to perform schema validation of the columns.

Whats the best way to get Table schema using jooq using table name.

DSLContext.meta() is taking so much time to get schema .

Thanks in advance

1 Answers

By default, DSLContext.meta() queries your entire database with all the schemas and all the tables, even if you only consume parts of it.

You can use Meta.filterSchemas() (and possibly even Meta.filterTables()) to filter out content prior to querying it.

Related