Trapping errors in WI description

Dart, Jocelyn jocelyn.dart at sap.com
Tue Oct 19 01:51:56 EDT 2004


Hi Mike,
&Attrib& will look at the contents of the attribute.
The contents is not <WI_OBJECT_ID...> - that's just what gets displayed if the attribute is empty.
So perhaps better to look for &Attrib& is initial - however even this is not failsafe.
Why not create a virtual attribute DBXXXX_found "flag" that checks at least one of the database attributes returns a value
and use that.
 
Regards,
Jocelyn
 
-----Original Message-----
From: SAP Workflow [mailto:Owner-SAP-WUG at MITVMA.MIT.EDU] On Behalf Of Michael Pokraka
Sent: Tuesday,19 October 2004 1:58 AM
To: SAP-WUG at MITVMA.MIT.EDU
Subject: Trapping errors in WI description
 
G'day all,
I've discrovered some slightly inconsistent behaviour on our 6.20/4.7 system.
 
I'm trying to determine if a DB table attribute fails in the WI text, in
order to avoid having '< _WI_OBJECT_ID.BLAH not found>' appearing in the
text.
 
So, methinks this is easy with a couple lines of sapscript. None of these
worked:
1: if not ( &Attrib& is initial )
2: if &Attrib& CS '_WI_OBJECT'
3: if &Attrib& = '< _WI.... (full text pasted in)'
 
Even more strange - if I reverse 2 above to 'if not (...', the same result.
So I think there's something weird about when it generates the message. Just
for fun I tried:
if &Attribute& > 'A'
and it worked, both with a valid and errored field value. Now I'm utterly
confused.
 
Can someone recommend a good way of checking for failed attributes/missing
elements? I want to avoid editing the object as the table attribute is from
the SAP standard supertype.
 
Any thoughts welcome,
Cheers
Mike
 


More information about the SAP-WUG mailing list