I was wondering if I can use the obsprev to display the obs previous to the current one. Basically, if there were 2 updates to an observation I need to be able to dsiplay the first one. Any help would be greatly appreciated.
Thanks!
George
OBSPREV would pull the last 'signed' value. you would have to use
LIST_OBS(observation,'Update',list_type,format) and reference the second value.
Jerroll,
Thank you very much, when I reference the second value would that go in replace of the "update"? What indiciates it is the second value?
Thanks!
{fn SecondPrevValue(obsterm)
{
local r = ""
local l = GETFIELD(LIST_OBS(obsterm, 'SIGNED', 'LIST', 'VALUEDATE'), "\n", "\r")
if SIZE(l) > 0 then
if l[SIZE(l)]=="" then
REMOVE(l, SIZE(l)) /* remove trailing null entry if present */
endif
endif
if SIZE(l) > 1 then
r = l[2]
endif
return r
}
}