Easiest way to tell if single step task and not a task in WF?

Kjetil Kilhavn kjetil.kilhavn at bluec.no
Wed Sep 12 07:46:15 EDT 2012


Onsdag 12. september 2012 13.27.20 skrev Kjetil Kilhavn:
> Fredag 7. september 2012 12.53.20 skrev Sample, Rick:
> > Hi all,
> > 
> > Doing some archiving, cleanup, etc.
> > 
> > Looking for the quickest way to tell if a task is a single step task and
> > NOT part of a WF?
> 
> <header>-top_wi_id EQ <header>-wi_id AND <header>-wi_type NE 'F'
An explanation is perhaps needed… My memory served me slightly wrong. It is 
not TOP_WI_ID I have used to identify these before. Single work items all have 
initial value in WI_CHCKWI) in my experience.

Your solution (<header>-parent_wi IS INITIAL) will give exactly the same 
result as far as I know, so it's just a matter of choice depending on which 
data you have available, if you have data available.
For database selections there is an index on WI_CHCKWI, but none on PARENT_WI. 
(There's also an index on TOP_WI_ID, but that is not much help since it has to 
be equal to another value instead of being a fixed value).

For the record, WFD_ID also seems to be initial for single task work items, 
but is not indexed.

To sum it up: for selection from DB the best choice should be WI_CHCKWI, and 
to check available data you have several options.

> 
> > If SWWWIHEAD-PARENT_WI = NULL, then this is in fact a simple
> > task? Like an IDOC task, etc.?
> > 
> > Rick
-- 
Kjetil Kilhavn (+47 40220607) - Blue Consulting AS (http://www.bluec.no)



More information about the SAP-WUG mailing list