Hi everyone,
Last week while doing code-level analysis for a 9.2 feature I noticed a bug in Usage Review. This bug will cause unpredictable ICWHSE quantity problems and other potential issues with data in the ICWHSE file.
There is not a KB article for this yet, but one should be created soon. The change is to ICE556, and here are the important lines of code:
Previous line:
21540 if usage_date_changed or usage_flag_changed or usage_qual_changed then changed_usage$="Y"; if nul(icwhse.last_disb_date$) or icrdst.usage_date$<icwhse.last_disb_date$ then icwhse.last_disb_date$=icrdst.usage_date$; write record (icwhse)icwhse$
New code:
21540 if usage_date_changed or usage_flag_changed or usage_qual_changed then {
21541 changed_usage$="Y"
21542 gosub UPDATE_LAST_DISB_DATE
21543 }
22700 UPDATE_LAST_DISB_DATE:! ^100,5
22705 extract record (icwhse,key=%a0$+whse$+item_num$,dom=*return)icwhse$
22710 if nul(icwhse.last_disb_date$) or icrdst.usage_date$<icwhse.last_disb_date$ then icwhse.last_disb_date$=icrdst.usage_date$
22715 write record (icwhse)icwhse$
22720 return
Any company that is using Usage Review should have this code applied immediately.
Thanks, Tim