dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #08634
timestamp on datamart
Hi
I'm looking at putting a timestamp column on the aggragateddatavalue
and aggregatedindicatorvalue tables. This is necessary if we want to
pull a "diff" of the aggrgatedXXXvalue table to only reflect values
which might have changed since last time we looked. Because the
datamart export uses a batchhandler rather than going through
hibernate I'm guessing it makes sense to generate the timestamp
updates manually - ie in exportDataValues method of
DefaultDataElementDataMart rather than depending on any hibernate or
database magic. Or could (or should) this sort of behaviour be pushed
into the batchhandler itself? I'm really not sure. My first instinct
is to say that timestamping a row is something which should really be
a framework thing and I shouldn't be writing application code to do
it. OTOH, to mix a metaphor, cleverness killed the cat ... if
exportDataValues() is the only place data gets exported to datamart
then just making new Date() and shoving it in is probably the easiest.
Anybody have any thoughts on this?
Cheers
Bob
Follow ups