IF and ABS condition statement in BEX query designer
Hi,
I would like to ask the best way for me to produce an acceptable result from Excel IF and ABS Condition statement.
The condition statement that I have on my Excel file is
=IF((A2-B2)>0,ABS(A2-B2),0)
I'm trying multiple times to reproduce this in BEX Query designer, unfortunately I'm getting a bad result or unacceptable formula.
Anyone who could help me with my issue?
Thanks,
Arnold
Hi Arnold,
Thank you,
Nanda
Similar Messages
-
Condition (Defintion) in BEX Query Designer
Hi Experts,
I am trying to define a condition in BEX Query Designer.
I defined my condition and bit confused with Characterstic Assignment
What Happens if is select 9What is the difference)
1) All Characterstic in the Drilldown Independtly
2)Most Detailed Characterstic Along the Rows
3)Most Detailed Characterstic Along Columns and
4)Individual Chars and Chars.Combinations
ThanksHi,
<b>● All Characteristics in the Drilldown Independently</b>
This setting allows you to apply a condition in a general way. Depending on which characteristics you use in the drilldown, you obtain different results.
Note that the characteristics that are already used in an active condition for characteristic combinations are not included.
This option is optimized for ranked list conditions, but can also be used for threshold value conditions with relative values.
<b>●Most Detailed Characteristic Along the Rows or Columns</b>
This option is optimized for threshold value conditions. The condition is applied to the most detailed characteristic of the rows or columns.
Note that this function is not supported when executing the query in the BEx Analyzer. For more information, see Restrictions in the BEx Analyzer.
<b>● Single Characteristics and Characteristic Combinations</b>
This setting allows you to evaluate the condition for characteristics or characteristic combinations defined for specific drilldowns only. You can select any characteristic (of the characteristics used in the query in rows, columns, or in the free characteristics) or a characteristic combination.
○ If you only want to evaluate the condition when a certain characteristic is present in the drilldown, select this characteristic.
○ If you want to evaluate the condition for characteristic combinations, select multiple characteristics.
Source:
help.sap.com
For more information and examples please check the following link:
http://help.sap.com/saphelp_nw70/helpdata/EN/73/702e39074dc93de10000000a114084/frameset.htm
Hope it helps. -
Where to write IF THEN ELASE statements in BEX Query Designer
Hi All,
I need to write a formula in query designer...
saying that to display the all Quantities in KGs.. Now articles are in Grams and KGs...
So here i need to perform calculation like... if article is in KGs divide by 1, else if article is in Grams divide by 1000.
where can i write this logic to perform calculation ...
Thanks in advance..
ravi.phi chetan,
No its not work.. why because i need to convert the unit of measure in Masterdata Attribute values... that means ) ' 0grooss_wt'. this is attribute as a keyfigure of ' 0material' .. this ' 0gross_wt' values has to convert in KGs. at Present ' 0gross_wt' values are in KG and Grams...
I can change these values in update rules by writting Routine.. But I need to convert it in KGS at BEX Query Designer Level..
I need calculate like this
quantity sold * Gross Weight.
here Gross Weight is the formula variable which replacing the values of gross weight...
i tried by creating conversion types in RSUOM t-code. but it works on keyfigures of infocube.. not on attribute values of master data...
is there any solution to solve this Problem... -
IF...ELSE.. STATEMENT in BEx Query Designer
Hi,
Why there is no IF, ELSE function in BEx Query Designer?
Assuming I need to write the following logic, how can it be accomplished?
IF (A=0 OR B=0)
THEN 0
ELSE IF ( B/A <0)
THEN ' *'
ELSE
B/A * 100
i.e.
if A or B is equal to 0, then display the value of 0
else if B is negative (as A is either 0 or positive), then display the following text: ' *'
otherwise, display the value of B/A * 100
Thanks!Hi,
You can achieve this by creating a new formula.
You have to use the boolean operations and mathematical functions. But we cannot display *. u have to display some value for that.
Khaja -
IF THEN ELSE STATEMENT IN BeX Query designer
Hi,
I want to write a query as follows:
IF <Value a> is available THEN <Value a> ELSE <Value b>
I have written it as follows:
(X>0)X+(X<=0)Y
The problem with this equation is, in case X = 0(number Zero) then Y is not getting displayed. But In case X =NULL (or no values) then Y displayed. This is leading to inconsistency in final result. Please help in rectifying the formula incase it is incorrect or is it because of some program bug in BeX?
Regards
MadhavThis works for me...dont understand y its not working with u!!
it is simple:
(X<>0)X+(X==0)Y
If X is 0, then 0X + 1Y = Y
else
1X + 0Y = X.
What result you are getting in both cases?
as you thing,X value is may not be 0 in your case. It may be 0.00004...something like that...Set Decimal Places to 5 or 6 to X.
Message was edited by:
Muralidhar C -
Results based on From and To value in Bex query designer.
Dear all,
We are using BI7.00. In one of our report which pertains to PM user wants to get the details of number of breakdowns which falls in the value range 0 to 1 hours.
I created a condition which has 2 variables, one is From value and the other is for the To value (since user wants to enter both the limits). I have written a condition that if the breakdown hour is greater than or equal to variable1 and less than or equal to variable2.
Using the above condition if the query is run, i am not getting the desired output. The values avaialble in the report are 0.65,0.78,1.30,7.38,0 etc., when i give 0 to 1 i should get the values 0.65,0.78 and 0 but instead report displays "No valid results".
I changed the condition and selected "Between" variable 1 and variable 2 - yet no change in the query.
To my knowledge i foresee that system is not able to recognize the decimal and hence provides details only based on the whole numbers.
How to get my requirement achieved in the Bex query designer.
Experts suggestion with steps will be very useful to solve my problem.
Regards,
M.M
Edited by: Magesh Magesh on Dec 26, 2008 11:28 AMHi Magesh,
I think you could try one more way.
Create a formula inserting your two formula variables for limits .(FV - are ready for input ) .
The formula would return the result as 1 or 0 because it would have boolean condition in it.
You could then place a condition in the query designer to only show all records where the value of the formula key fig is 1.
You formula A would look like
( KF > FV1) AND (KF < FV2) * 1.
And in the condition put A EQ 1.
You could scale the key figures as well and multiply the limits mentioned by the users in FV1 and FV2 if decimals are still not recognized by SAP.(scaling)
Regards,
Sunmit. -
Usage of formulas in conditions in BEx Query Designer
Hi guys,
does anybody of you guys know, if it's possible to use the results of formulas in conditions? I tried it, but the result of the query was "No applicable data found", but there are data for the selection.
When I'm defining the condition with the key figure (no restricted or calculated key figure), then the query can be executed.
In my case, I like to define a condition based on a formula result. The value should only be displayed, when the result is greater than 30.
Any ideas or are there any bugy in the BEx Query Designer?
Thanks a lot + best regards,
ClemensHi Clemens,
I have created a condition in my own system based on formula and it works perfectly fine. Please check following points in your condition change mode,
1) Condition is marked as Active.
2) In the block "Evaluate condition below for" you will have to select "All characteristics in drilldown Independently". If you have selected combination of characteristics then you will have to maintain proper sequence otherwise your condition will not work.
3) In the next block when you set the condition, click on new, in the first block select your Formula from dropdown and set the proper operator in your case you will have to select "Greater than" in the next column set the value of key figure and just trasnfer it.
Now you are ready to use the condition.
Regards,
Durgesh. -
Options in Assignment of Condition in BEX Query Designer
Hi Experts,
I am trying to define a condition in BEX Query Designer.
I defined my condition and bit confused with Characterstic Assignment
What Happens if is select 9What is the difference)
1) All Characterstic in the Drilldown Independtly
2)Most Detailed Characterstic Along the Rows
3)Most Detailed Characterstic Along Columns and
4)Individual Chars and Chars.Combinations
Thankshi,
chk the link
Query creation
http://help.sap.com/saphelp_nw70/helpdata/EN/f1/0a5625e09411d2acb90000e829fbfe/content.htm
http://help.sap.com/saphelp_nw70/helpdata/EN/42/d21c1f46076bb2e10000000a1553f6/content.htm
Ramesh -
Difference between aggregation and calculation tab in BEx Query Designer
HI,
I am using BEx Query Designer for my report, for the key figures in the coloumn area i slected one numeric key figures, in the properties tab i found aggregation tab and calculation tab.
I need to sum up the total values for that particualar coloumn, when i used calculation tab i found to sum all the values for a particular coloumn, then what is the use the aggreagation tab?
I not able to used that Aggregation tab it is showing as a hidden fields...
can any one tell me whats the exact difference between these tabs and when we need to use which tab?
With Regards,
Thanesh Kumar.Hi Thanesh Kumar,
I moved this thread from forum Data Warehousing to Business Explorer since it is a query related question (as SDN moderator).
I could explain to you the difference between these two tabs.
For "calculation" tab, it changes the display of result and does not change the calculation logic.
It means that, if this key figure is used further in formula, still the original number (without "calculation" tab setting) is used for further formula calculation.
For "aggregation" tab, it changes the real calculation logic.
The system takes the setting as the aggregation rule for records.
The most common aggregation rule is of course summation. If you set to e.g. Average here, the system does the
Average instead of summation when aggregating records. And the Average value will be taken for calculation
in further formulas or other calculations.
For "aggregation" tab, you could only use it for CKF (calculated key figure) or formula and you could not use it for
a basic key figure. That should be the reason why you see it greyed-out.
Regards,
Patricia -
Problem with Queries Structures in Bex Query Designer and Universe Designer
Hi everyone,
I have a problem when i try to do a Universe from a Bex Query Designer.
When I use a Characteristic Restrictions in a Structure, the universe only show me the structure without the objects inside it.
EJ:
1) Bex Query Designer
Colunms
(Structure) ZSRT_123
- (Characteristic Restrictions) Reg Guayana
> (InfoObject) 0Product = 'XXX'
> (InfoObject) 0Country = 'YYY'
- (Characteristic Restrictions) Reg Caracas
> (InfoObject) 0Product = 'AAA'
> (InfoObject) 0Country = 'BBB'
Rows
(Structure) ZSRT_456
(Key Figure) Net Sales
2) Universe designer
(Class) ZSRT_456
>(Measure) Net Sale
(Class) ZSRT_123
>(Dimension) ZSRT_123
The universe dont translate the two Characteristic Restrictions in the structure ZSRT_123.
Any information would be much appreciated. Thank you.Hi,
I assume that you are using BOE XI 3.1 SP2.
We have added an option in SP2 to generate or not the L00 level.
Unfortunately this option applies not only on characteristics but also on hierarchies, hierarchies variables and structures: that's the reason why you have no elements belonging to the structure generated.
I recommend to always generate L00 in order to have your structure generated correctly.
This issue will be fixed in SP3.
Regards,
Didier -
Doubt on Rows and Coloums in BEx Query Designer.
Hello, Experts.
I have a Doubt in BEx Query Designer.
In the Rows I have a Fiscal year Period, if the user enters the Fiscal year period for e.g. : 001/2006 .
in the columns i have forecast for the Fiscal year period which user entered ( 001/2006 ), and we have another column pervious ( Prior )fiscal year period ( 001/2005 ).
My Questions is , as we are Restricting with 001/2006 will the query retrieve the values of 2005 or not?
Thanks in Advance .
Sharpyes i am Doing Offest.
I moved this Fiscal year Period to Free char, and i Restricted with Pervious Fical Year period and Fical year period . it worked. but
when i kept this in Rows and deleted Previous Fiscal Year period . it is displaying blanks. in prior years forecast.
is it because i am Ristricting it to only fical year period which user entered
Colums--> Forcast ( User Entered year ) Prior year
Rows
Fiscal year period
Fiscal year period( user enterd )
Thanks -
Conditional Formating in Bex Query
Hi Folks,
Here requirement is like..if the value is +ve it should show <b>upward arrow</b> and -ve it should show <b>Downward arrow</b> in Bex query result besides a particular value.
could any one let me know what formula is required in Analyzer/Designer or is there any option to display..To show up arrow and down arrow for +ive and -ive result for the bex query result. You can modify your web query with the table interface. Table modify class.
Please check out this two document:
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/403c789a-aafb-2910-e5a4-835645f0721b
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/49dfeb90-0201-0010-a1a2-9d7a7ca1a238
Thanks
Mona -
BEx QUERY DESIGNER AND QUERY ANALYZER
HI!!!
I want to learn to use the BEx Query Designer and the Query Analyzer, someone can help me with link, manuals, tutorials, cookbooks, everything about this?
Thanks and regardsHi,
Please check the links below which may help you.
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/webcontent/uuid/a8cd1f71-0a01-0010-4783-f119b6132d25
https://www.sdn.sap.com/irj/sdn/bi-elearning
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/webcontent/uuid/ba95531a-0e01-0010-5e9b-891fc040a66c
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/27388d45-0c01-0010-9ebf-9b3dd7bd4ce6?prtmode=navigate
http://help.sap.com/saphelp_nw04s/helpdata/en/05/4b583cf7388362e10000000a114084/frameset.htm
https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/92a25985-0a01-0010-5ea0-99ff9e0a244a
http://help.sap.com/saphelp_nw04s/helpdata/en/42/d21c1f46076bb2e10000000a1553f6/frameset.htm
Regards,
® -
How to remove pound symbol # and preserve leading zeros in BEx Query
Hi,
I have two questions regarding the display in BEx Query.
1. How can I remove the pound symbol # for blanks in BEx Query?
2. How can I preserve leading zeros? At the moment, value "001" will be displayed as "1". But I need the leading zeros.
Thanks.
JoonHi ,
You can apply these settings in Bex query designer.
If you need to remove pound symbol jsut make a new formula and use NODIM function you will find this function under data functions.
So NODIM(Your price keyfigure) this will remove the Pound symbol.
For # just find out against which characterstic you are getting # then go to default values panel there you will find all your characterstic which you are using in report---Rt click -Restrict-single valuesdirect input-#-Move to selection(That forward arrow)--select that # and choose exclude from selection (That red square icon).
And yes for leading zeros check out this thread
Leading zeros not displaying
Hope it helps you.
Regards,
AL
Edited by: AL1112 on Jun 9, 2011 1:43 PM
Edited by: AL1112 on Jun 9, 2011 1:47 PM -
Future of BEx Query and BEx Query Designer
Folks, I understand SAP's future reporting tools is BO suite. All of us need to move to the new tools which are better or more reliable in 2010. Meanwhile our customers are reluctant to use BEx tools for any new development. Being on the techi side I dont see how BEx Query will be replaced by Voyager or Polestar or WebI or Crystal. I just need to report on my multiprovider without a universe layer. Have any of you experts come across documentation that layed out future of BEx tools explaining the end of support period? I have see roadmaps for tool availability but no dates for end of support.
Thanks in advance.AFAIK,
Bex Query designer and BEx query will continue... Polestar might be proposed as an alternative for BEx but then it is meant for ad-hoc analysis ... but BEx query and Query designer have specific query requirements also...
Voyager etc will start coming in...
Maybe you are looking for
-
Issue to drill down from a report
Hi, Our requirement is we need to show three different graphs in a single report representing different data, from that we need to drill down to a new different report ; Two approaches we tried with crystal report are; 1. We put three graphs and
-
How do I add a password to my list?
when i go to the PayPal site i am not asked if I want to save password. How do I add my password and the paypal web to my list of passwords?
-
1st gen iPod Touch will not update past 1.1.5
I am sure this question has been asked before and probably answered but I have tried just about everything I can think of and I cannot get an update past 1.1.5. I have restored my unit and downloaded firmware files for 2.2 and 3.1 but both give me an
-
Everything is gone after the update, there are no apps on the ipod, neither on or in itunes
-
Hi Experts, Please help me how to acheive the below for master data Requirement Create a Infoobject ZCAORD i) Extraction job from R/3 Use ZWBS rule as template Similar to ZCORD (get key & text f