> Concern 1 was why the heck you didn't have a uniform API. (Right now I can > understand that DSL design obviously necessitated this, but not then!)
The "non-DSL" API was added to jOOQ very early. It was later wrapped by the "DSL" API. Both provide exactly the same functionality. For a long time, I actually hoped I could eventually deprecate the first in favour of the latter. It turned out that for dynamic SQL, the first is very useful - just as in your case. Any ideas to somehow consolidate the two "partial" API's for a future major release is very welcome. > Concern 2 was if I take SelectQuery approach somehow I would be limited by > its API. After all you had to write lots of API classes to achieve all the > features. Your point 2 takes care of that. Nope. By the fact that the DSL API only wraps the "non-DSL" API, both API's share exactly the same functionality. Under the hood, they use the same implementation classes. > Regarding point 3 though, there is an issue. FactoryOperations doesn't > expose the count() method or field method - only Factory class does this. > Since I was injecting into the interface, never would have noticed this > until you pointed out - something that may need better documentation. Static vs. non-static query part construction has been discussed several times recently. Essentially, the problem some users may face is the fact that jOOQ mixes query construction (stateless, immutable, preferably static) with query execution (stateful, mutable, preferably non-static). A recent discussion can be seen here: https://groups.google.com/d/topic/jooq-user/hBceRSbufg8/discussion On the other hand, FactoryOperations was recently introduced by Sergey Epik, precisely to be able to use it along with Spring and data sources. That has also been resolved with the upcoming jOOQ 2.4.0 where Factory can take a data source rather than a JDBC connection: https://groups.google.com/d/topic/jooq-user/eiwxsnVPWV0/discussion In any case, you don't need any Factory state to produce a count() field. I can see that this can be confusing for a new jOOQ user. Historically, all QueryPart objects held references to Factory objects (Configurations), including SQLDialect and Connection objects. This is no longer the case. You can safely call Factory.count() without any Spring involvement. > On your first question regarding documentation, I would say samples would > help. Probably you can explain various use cases in your blog. OK, I see. Anyway, the manual will be greatly re-worked with jOOQ 3.0 in late 2012 > All in all I have to say I am impressed with what you are doing and your > commitment to it. Thank you Cheers Lukas
