How Do I know which functions were performed to get this truth table?
Any help Appreciated
The truth table:
The algebraic expression is:
Sum of products: ~y*~z+x*z
Product of sums: (x+~z)*(~y+z)
Related
Could you help me with DAX calculation for :
=IF(C11=0,"- ",(C21+C26)/C11)
CONDITION
,this is an excel calculation i want same calculation in DAX,Power BI
as per above image
The data isn't structured like a table in power bi. First structure your data into a normalized table format.
Which would your columns will be
Product category Amount
If you have a way to explain your logic that would help. If you write out your logic then maybe that would clarify what you need
To get the answer you want, you will need to do some filtered measures on based off of the product category once you normalize the data. I suggest adding it to power bi and giving it a shot
I have a table that just contains all articles.
Then I have a transactional table that contains a value that I would like to use for the rank. THe same tables has the department information.
The structure is like:
Now I would like to get the Ranking based in Value, in the end represented in a matrix.
This function shows me the ranking based on the value:
RANKX(ALLSELECTED(Article),[Value])
If the matrix just contains Article in the rows, then it works.
But when I add department, then the Rank is calculated for each department.
How can I get the RANK for each Article regardles of the Department?
I'm assuming that you are creating a measure and that you are putting the results in a "table", rather than a "matrix". If so, then the following DAX works for me.
Rank = RANKX(ALLSELECTED(Table1), Calculate(Max(Table1[Value])))
Note that this is when all of the data comes from a single "Table1". You may need to make updates to the measure above based on your table structure and names.
Let's assume a simple table:
I would like to find provider name for a given person_id before a specified date. For example if I specify 1/1/2015 the output should be "Third".
It's easy enough to do so if the table is sorted by person_id and descending by the status date (as on the picture above), but is there a way to do it without sorting the table in any way?
The nearest date before the specified for person can be found by the following array formula:
{=INDEX(Table2[provider],MATCH(1,--(MAX(((A20=Table2[person_id])*(B20>Table2[status_date])*(Table2[status_date])))=Table2[status_date])*(A20=Table2[person_id]),0))}
I don't have a direct answer, but you might investigate Power Query and this link:
https://community.powerbi.com/t5/Desktop/How-do-I-pass-parameters-to-my-SQL-statement/td-p/118716
(Courtesy of Greg_Deckler - https://community.powerbi.com/t5/Desktop/How-do-I-pass-parameters-to-my-SQL-statement/td-p/118716)
Essentially, the premise is to use Power Query to "build/extract" a sub-table (and sort it) on the fly...
Hope that helps.
I'm looking to create a dax calculated column that uses two related tables. one is a dimension one is a fact. in MDX it looks like this:
Sum(
{[Tbl Master Measure Mapping].[Str Busies].[True]}
,[Measures].[Int Calls Offered]
)
in t-sql it looks like this:
select int_CallsOffered from fact_CallType_OTS a
inner join tbl_MasterMeasureMapping b on a.entName = b.entName
where b.Str_Busies = 'True'
Pretty Straight forward. This works in a cube no problem. How can i translate the above to a dax formula in power pivot ? would this be a measure or a calculated column ? i'm thinking calcualted column. I've looked on the internet, and a term "Evaluate" comes up, but i don't find that function in my version of power pivot. maybe i'm behind ? but i'd love to find a solution where i join just two tables (which i've defined the relationship on) and get a value back based on the where clause. Thanks.
b
You could create the measure using the CALCULATE function.
Call type OTS total:=CALCULATE(sum([Int Calls Offered]),'Tbl Master Measure Mapping'[Str Busies]=TRUE)
Note: your TSQL and MDX would not return the same thing as the TSQL is not aggregating
see https://msdn.https://msdn.microsoft.com/en-us/library/ee634825.aspx
I am using the multiple dimensional model in SSAS with a seemingly simple requirement.
I have a Product dimension table with a Price attribute. Using Excel pivot-table, I want to filter this Price attribute, for example "greater than $1000". However the filter in the pivot table is a string only, hence I can not do perform any numerical comparison operations, but rather for equivalent strings, e.g. "$1,000.00".
My problem is similar to this thread, and I wonder if there is a solution/work around that I missed?
Best regards,
CT
As suggested in the thread that you link, you could create a measure for the price, and then filter that. The definition of this calculated measure would be something like
[Product].[Product].Properties("Price", TYPED)
assuming the dimension as well as the attribute are named "Product", and the attribute has the price defined as a property named "Price".
(You define a property in BIDS as a relationship from the Product attribute to the Priice attribute.)