Hi Marko,

2013/10/26 Marko Topolnik <[email protected]>

> Hi Lukas,
>
> I think I'm still missing something regarding #2704: it seems to me that
> this issue is about *fetching* a record from the db, then updating it
> with incoming data from a request.
>

Mostly, yes, although other use-cases aren't excluded per se.


> On the other hand, I am keen on avoiding any fetching: I want an
> unconditional UPDATE tableX SET (columns_to_update) WHERE
> (these_columns_match). The values for both column groups come from a JSON
> request, uniformly in a single map, and the service layer must know in
> advance which values belong to which group. Note that, in general,
> these_columns_match is not required to form a unique key: in that case many
> database record may be updated. This is the main reason why I don't want
> fetching, but even if they do form a unique key, I may want to perform bulk
> updates, where again fetching would hurt performance and complicate the
> logic.
>

> All said, I am quite satisfied with the solution I already have and I
> believe I can improve on it using executeUpdate(R, Condition).
>

I see, so yes, the executeUpdate() with Condition method is really the most
appropriate way to go forward for you, specifically, once it is possible to
influence "null" semantics with respect to a Record's changed flags.

Cheers
Lukas

-- 
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.

Reply via email to