on 2013 Dec 17 5:29 AM
Dear All,
I want to put a conditional output based on the phrase maintained in a characterstics.
For example: if a characteristics "SAP_EHS_1018_001" contains a phrase "No Data Available",
then another phrase "Remarks" shall not appear on the output report.
Output:
No Data Available
But if the phrase maintained for the characteristic "SAP_EHS_1018_001"
contains a phrase other than "No Data Available", then the other phrase along with"Remarks" shall appear on the output report.
Output:
Remarks:abcdefgh(The other phrase)
I also tested the below code and it works:
<11BRG044(M,SAP_EHS_1018_001;*)>
<13BNG116(+:01G1018001RE)>
<15BIF000(AND:01G1018001RE LK "no data available")>
<15CIF000>
<03EHS_L_TEXT(CED-E11.00900050)[D:Remarks]>:
<15EIF000>
<11BRG003(D;*)>
<01G1018001RE(P;*)>
<11ERG003>
<13ENG116>
<11ERG044>
But the problem is the report can be generated in different languages.
So if I generate the report in any language other than English (EN), the above code fails.
And it does not look good, if I code with "OR" logic and put the phrase "No Data Available" in all the languages in the conditional check.
Is there any other way of doing this.?
Would really appreciate if there is some other way of doing this.
Thanks in advance.
Best Regards,
Aarohi
Request clarification before answering.
Dear Aarohi
you should avoid if possible to use such WWI logics... many people love to use this kind of logics;
yes they are possible; but just using different maintenacne approach can do the same "trick".
Example: normally many of the WWI reports generated need to be shared with customer. "No data available" is a "bad" choice to print; Most of the EHS Classes contains a characterisrtic called "Remarks"; Now it depends "only" on clever use of data maintenance to make sure what will show up in WWi report without any WWI logic.
C.B.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Aarohi,
As Peter explained make the check language-independent by looking for the phrase key instead of the text. That will do the trick.
Ralph
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You shouldn't be comparing the text using conditional output. You should be looking at the phrase id. For example, <15BIF102(AND:01G1018001RE(K) LK "CUST-XXXXXXXXX")>
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi !
Really tricky demand !
In conditional Output, you are comparing a string, “No Data Available” against a phrase assigned (in English).
Based upon the outcome you are printing the “Data” as ‘Phrases’.
Ok. Your code works fine for one report language – English !
Now you want to extend it to other languages that would come up in the final report !.
Here you can use Repeating Group of Type – “Validity Area, Language”.
But the problem comes in the conditional output !. Because every time you are comparing the string, “No data Available” against the possible phrases in the “Remarks”.
Eg. If the report language is German, you would get the phrase, ‘Keine Daten verfügbar’ to compare with your comparison string. In that case, your condition would fail. If you further explain or give hint about your business process for this, it would be easy to discuss the logic !
Regards
Subash Sankar.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Aarohi
the topic about “Conditional output” has been discussed very recently. Refer below threads
http://scn.sap.com/docs/DOC-48359
http://scn.sap.com/thread/3444598
Balajee
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
8 | |
2 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.