Digest for jooq-user@googlegroups.com - 4 updates in 3 topics

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Digest for jooq-user@googlegroups.com - 4 updates in 3 topics

http://groups.google.com/group/jooq-user/topics mailing list
Lukas Eder <[hidden email]>: Sep 30 08:53AM +0200

Hi Samir,
 
Use DSL.currentDate().minus(1)
 
Thanks,
Lukas
 
Samir Faci <[hidden email]>: Sep 30 07:56AM -0700

Haha, nice much easier.
 
 
Marshall Pierce <[hidden email]>: Sep 30 07:39AM -0700

One more...
 
It'd make integration with Kotlin coroutines (OK, that's not just Kotlin
the language...) easier/possible to have something like `transactionResult`
that instead of taking a `TransactionCallable` and doing all the
ManagedBlocker bits, took something whose `run()` (or equivalent) was a
`suspend` function. In Kotlinese, that could be simply a function type:
`suspend (Configuration) -> T`.
 
My current use case is that I'd like to be able to kick off some
fire-and-forget async work inside a transaction, and for various reasons
I'd prefer to have that be done via coroutines rather than
`CompletableFuture` and friends (e.g. coroutine context carries over to
child coroutines, unlike threadlocals, and other such things).
Lukas Eder <[hidden email]>: Sep 30 08:47AM +0200

That's a feature not a bug! :) jOOQ by default quotes all identifiers.
That's useful to support all the edge cases of case sensitive identifiers,
or identifiers containing special characters by default (other ORMs have a
lot of trouble with these). It also protects against SQL injection, if
users forget to sanitise their inputs to DSL.name().
 
The problem in your case is that you're creating your objects using JDBC
directly, using Derby's default case (UPPER CASE), and then request data
from quoted "lower case" identifiers. You have several ways to work around
this:
 
- Create the schema using jOOQ API as well. We support a lot of DDL
statements that you could use
- Use the code generator
- Use DSL.unquotedName()
- Use RenderNameStyle - as you did
- Use the plain SQL API (DSL.field(String), instead of DSL.field(Name))
 
I hope this helps,
Lukas
 
You received this digest because you're subscribed to updates for this group. You can change your settings on the group membership page.
To unsubscribe from this group and stop receiving emails from it send an email to [hidden email].