Тёмный

How to use DAX in Power BI | Microsoft Power BI for Beginners 

Alex The Analyst
Подписаться 816 тыс.
Просмотров 171 тыс.
50% 1

In this series we will be walking through the basics of Microsoft Power BI. In this video we will be walking through how to use DAX in Power BI.
Download Microsoft Power BI: powerbi.microsoft.com/en-us/d...
Download Apocalypse Dataset: github.com/AlexTheAnalyst/Pow...
Favorite Power BI Courses:
Power BI for Business Intelligence - bit.ly/3Nfi59i
Power BI A-Z - bit.ly/3MkpYKw
____________________________________________
SUBSCRIBE!
Do you want to become a Data Analyst? That's what this channel is all about! My goal is to help you learn everything you need in order to start your career or even switch your career into Data Analytics. Be sure to subscribe to not miss out on any content!
____________________________________________
RESOURCES:
Coursera Courses:
📖Google Data Analyst Certification: coursera.pxf.io/5bBd62
📖Data Analysis with Python - coursera.pxf.io/BXY3Wy
📖IBM Data Analysis Specialization - coursera.pxf.io/AoYOdR
📖Tableau Data Visualization - coursera.pxf.io/MXYqaN
Udemy Courses:
📖Python for Data Analysis and Visualization- bit.ly/3hhX4LX
📖Statistics for Data Science - bit.ly/37jqDbq
📖SQL for Data Analysts (SSMS) - bit.ly/3fkqEij
📖Tableau A-Z - bit.ly/385lYvN
Please note I may earn a small commission for any purchase through these links - Thanks for supporting the channel!
____________________________________________
SUPPORT MY CHANNEL - PATREON/MERCH
🙌Patreon Page - / alextheanalyst
💻Alex The Analyst Shop - teespring.com/stores/alex-the...
____________________________________________
Websites:
💻Website: AlexTheAnalyst.com
💾GitHub: github.com/AlexTheAnalyst
📱Instagram: @Alex_The_Analyst
____________________________________________
0:00 Intro
0:35 Looking at the Data
1:08 Creating a Measure
1:43 DAX - Count
3:30 DAX - SUM
4:43 SUM vs SUMx
10:19 DAX - Date Functions
13:50 DAX - If Statement
14:55 Outro
All opinions or statements in this video are my own and do not reflect the opinion of the company I work for or have ever worked for

Опубликовано:

 

14 июл 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 152   
@gaminggunz8316
@gaminggunz8316 16 дней назад
Alex, I get it you just used some random examples to explain sum and sumx and you explained them pretty well. But the profit result value is wrong, you can't calculate profit by (sum(all selling prices)-sum(all cost prices) * sum(all units)) because each product has different selling price and cost price. correct method is: for each product = SP-CP * units sold(of that particular product) then sum all these values correct profit value = 43212.43 Love your content. helped me a lot
@rudrapratapsingh1820
@rudrapratapsingh1820 4 дня назад
bro he done exact same thing, and what u did is what he wanna conbvesy the difference between sum and sumx, to get the individual sum from sumx like u said in ur ans.
@nayeem3905
@nayeem3905 Год назад
If people learn the DAX theories properly such as row context, filter context, context transition and iterators then you're on the path of becoming a pro at DAX.
@Goddibaba
@Goddibaba Год назад
Thanks bro
@Aviji2525
@Aviji2525 10 месяцев назад
@nayeem3905 Any youtube channel for these DAX basics?
@monisolaoyeyemi6019
@monisolaoyeyemi6019 Год назад
Thanks so much Alex for taking your time to break this down to the smallest bits for us. I have gained a lot from this video.
@stevscol
@stevscol Год назад
Great job explaining this. I am an absolute whiz with excel and just after watching your video, never using Power BI, I feel like I could open it up and start creating some pretty useful tables and graphs. Really appreciate you taking the time to create this video.
@AlexTheAnalyst
@AlexTheAnalyst Год назад
Happy to do it! I love making these tutorial videos :)
@ThatDudeRyan
@ThatDudeRyan Год назад
This was Microsoft's plan with PowerBI running on Power Query and M language.
@wilsonman8661
@wilsonman8661 Год назад
Alex, you probably already knew this and did it just for demonstration purposes, but for anybody watching this, SUMX is redundant in a calculated column the way it was used here because in a calculated column, it's already evaluating row by row. The below would've worked just the same in this example at 10:05: ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * [Units Sold] Second note (because this took me way longer to stumble across than I would've liked!): Instead of nested IF statements, look into the SWITCH function. It essentially lets you put all the conditions you would've put in a nested IF into one function. :D EDIT: I meant to mention that Alex will be one of only four people ready for the apocalypse when it hits. I see you on the list of customers, Alex. 😂
@AlexTheAnalyst
@AlexTheAnalyst Год назад
Lolol good tip and absolutely :D
@christinawu3116
@christinawu3116 Год назад
Hi Wilson, thanks for pointing out the redundancy of SUMX. Could I please add that the formula you mentioned could have a little correction for [Units Sold] which comes from 'Apocolypse Sales' table. Below is a revised version that works: Profit_Column = ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * sum('Apocolypse Sales'[Units Sold])
@wilsonman8661
@wilsonman8661 Год назад
@@christinawu3116 Hey Cristina, you're totally correct. I meant to use the [Sum of Products Sold] measure Alex created in the Apocalypse Sales table, which is also effectively what you're referencing in your correction here. Thanks for pointing that out. :D
@TheDavesterist
@TheDavesterist Год назад
@@christinawu3116 That revision doesn’t work, either. Both the sumx and your revision give the incorrect answer. What you get if you do that is the profit of a product * the sum of all products in the sales table. It should be the profit of a product times the sum of only that products sales. I made a separate column in apocalypse store column and made it equal to the measure [Sum of Products Sold] that was done earlier in the video. That gives the correct amount of product sold for each product and named it Products_Sold. Then I used that column to multiply it to the profit. So ([Price] - [Production Cost]) * [Products_Sold]. That will give you the correct profit.
@arindamnaha9503
@arindamnaha9503 Год назад
@@christinawu3116 Thankyou so much
@leviticus3
@leviticus3 Год назад
I'm learning so much from your Power BI playlist! Thank you for these!
@Magmatic91
@Magmatic91 Год назад
Love this new series. Keep up the great work Alex !
@TheDavesterist
@TheDavesterist Год назад
Hey Alex. I hope you get to read this. The profit that was calculated with SUMX is incorrect. You multiplied the profit of each product with the sum of all products sold instead of the sum of each individual product. I made a separate column in apocalypse store table and made it equal to the measure [Sum of Products Sold] that was done earlier in the video. That gives the correct amount of product sold for each product and named it Products_Sold. Then I used that column to multiply it to the profit. So in a new column I put ([Price] - [Production Cost]) * [Products_Sold]. That will give you the correct profit.
@TheDavesterist
@TheDavesterist Год назад
If anybody knows a cleaner way of doing it, let me know. I couldn’t figure out how to do it without making that extra Products_Sold column I made.
@mahimaparekh6254
@mahimaparekh6254 Год назад
@@TheDavesterist hey, i was able to do it by adding 'RELATEDTABLE' before the column name. This is the formula i used Profit Column SUMX = SUMX(RELATEDTABLE('Apocolypse Sales'), 'Apocolypse Sales'[Units Sold] * ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]))
@absoon9971
@absoon9971 9 месяцев назад
@@mahimaparekh6254 That was helpful. Thanks!
@kanamagg
@kanamagg 6 месяцев назад
@@mahimaparekh6254 thank you very much from Kazakhstan!)
@sanjakesic6142
@sanjakesic6142 4 месяца назад
Thank you so much for your answer@@mahimaparekh6254!!
@champmotivation2155
@champmotivation2155 6 месяцев назад
Hello Alex Thank you so much for sharing this. I think you made an error at 09:04 . I think first you were supposed to calculate profit for each Product which will be Profit_for_each Product = 'Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost] then you calculate total_profit for each product which will be Total_Profit = 'Apocolypse Sales'[Sum of Products Sold] * 'Apocolypse Store'[Profit_for_each Product]
@LinhNguyen-tg3vp
@LinhNguyen-tg3vp 4 месяца назад
I believe so as well. Also, when performing the SUMX, it's better to just add it as a measure instead of a column in the table. That way we can get the total profit for each product and the aggregated profit for all products as well.
@yanpaucon1043
@yanpaucon1043 2 месяца назад
Thank you. That means the Profit_column as well is incorrect 434754.87 if I will total all profit each product.
@yanpaucon1043
@yanpaucon1043 2 месяца назад
The correct total is 43,212.43
@akinfelabernard6358
@akinfelabernard6358 Месяц назад
There was a mistake there
@murtazabhutta278
@murtazabhutta278 Год назад
Short and to the point. Best! 👍
@abbielmi9163
@abbielmi9163 Год назад
Hey Alex , good video .You are good teacher for real. Hopefully u get the time to do more videos on power bi and dax. Took your advice annd I completed the GDA courses at coursera and got my certificate. Thank you for that. "Great courses". I felt power bi should be included as well.
@inspiringmind2996
@inspiringmind2996 5 месяцев назад
Hey Alex , You are an amazing teacher for real. Thanks a lot for explaining these concepts so well . Its really helping all of aspiring Data and Business Analyst a lot. I really feel your videos are very engaging and so informative .
@brittneysegar4972
@brittneysegar4972 10 месяцев назад
Great video! def feeling more comfortable with DAX expressions!
@ginohobayan001
@ginohobayan001 10 месяцев назад
Thanks for this Sir Alex! Really helpful series.
@promiseatiti248
@promiseatiti248 Год назад
Thank Alex for this. It doesn't make sense yet because I'm just getting started on my Data Analysis Journey but I'm hoping to come back here in a few weeks and brag about how this video is useful for me. P.S. I've saved this in my RU-vid Library for future references.
@ahmetalperenyildirim6184
@ahmetalperenyildirim6184 Год назад
Alex thank you for this series, that was exactly what I need and I directly searched with your name to learn in a formal way!!
@eagerbeever22
@eagerbeever22 3 месяца назад
This is so well explained & it definitely helped me in preparing a report as an assignment! Thank you so much for sharing your knowledge & expertise!
@peroverodexi
@peroverodexi Год назад
I always wince at your battle cry of "WHATSGOINGONEVERYBODY!" :)
@alishafaghi
@alishafaghi Год назад
Amazing Thanks Alex
@mohamedtalat6401
@mohamedtalat6401 14 дней назад
Thanks so much, Alex
@MphoSikwe-yp6rx
@MphoSikwe-yp6rx 6 месяцев назад
Hi Alex, thank you very much for this clear and well articulated video. Makes the learning experience a bit easier. To more tutorials and development :)
@user-mh3mw7fk9w
@user-mh3mw7fk9w 23 дня назад
great explanation between sum and sumx function
@PreciousAfricanStoryz
@PreciousAfricanStoryz Год назад
Amazing thanks Alex
@leylaalkan6630
@leylaalkan6630 Год назад
Hey Alex, great job! I just wanted to give you a quick heads up about a small correction that needs to be made to the calculation for the Profit column. It seems like the formula used in the video isn't giving the right results. Here's a suggestion for a different formula that should work better: Profit = ('Apocolypse Store'[Price]-'Apocolypse Store'[Production Cost])*SUMX(VALUES('Apocolypse Sales'[Product ID]),CALCULATE(SUM('Apocolypse Sales'[Units Sold])))
@alicevaleina3479
@alicevaleina3479 Год назад
This works perfectly. But we already had profit measure so you are giving formula for Profit_Column_SumX just so people don't get confused.
@abosedetowoju5083
@abosedetowoju5083 Год назад
Hi can you drop a measure for 'PROFIT' . The one in the video is wrong. Thanks
@arindamnaha9503
@arindamnaha9503 Год назад
@@abosedetowoju5083 use this Profit_Column = ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * sum('Apocolypse Sales'[Units Sold])
@anishkavelusamy8874
@anishkavelusamy8874 Год назад
The Above formula works perfectly. Profit_column_Sumx= ('Apocolypse Store'[Price]-'Apocolypse Store'[Production Cost])*SUMX(VALUES('Apocolypse Sales'[Product ID]),CALCULATE(SUM('Apocolypse Sales'[Units Sold]))) Example: The calculation for product Id 10001 is Profit_column_sumX= (30.99-13.67)*390 is 6754.8. The answer in this vedio is not correct. but if we use the above formula we are getting the proper result. Thanks Leyla Alkan.
@ysharbat
@ysharbat Год назад
@@abosedetowoju5083 Hi. Profit = SUMX('Apocolypse Store',('Apocolypse Store'[Price]-'Apocolypse Store'[Production Cost])*SUMX(VALUES('Apocolypse Sales'[Product ID]),CALCULATE(SUM('Apocolypse Sales'[Units Sold]))))
@wikinews7367
@wikinews7367 11 месяцев назад
Very helpful
@JD_2
@JD_2 Год назад
good stuff 👍
@1992supergamefreak
@1992supergamefreak 7 месяцев назад
At 9:04 It is mentioned that Apocalypse Sales is the table we are looking here, but the table we were working on was Apocalypse Store. Can you explain that part please? Also, when I tried to change the Sales to Store in the SUMX, it gave error. I am new to PowerBI, so maybe asking a bad question, but it would be helpful if I could get an explaination. Thanks.
@danieljohnson454
@danieljohnson454 4 месяца назад
Please where did he get the data from?
@MAR.A.BUQ.
@MAR.A.BUQ. Год назад
Thanks Alex, simple and clear explanation, but what is the difference between a conditional column and IF statement? can we use it instead of using IF?
@samiissam2113
@samiissam2113 Год назад
Hi Alex thank you so much for your videos ..but unfortinately i couldn't understand the part of SUMX i tried to calculate by myself but i found different results for every customer
@uniqueben6138
@uniqueben6138 4 месяца назад
Alex, thank you so much for breaking this down. please i am finding it difficult to copy and paste the Dax formular from the bar
@thaynangamarano3340
@thaynangamarano3340 Год назад
Hey Alex, Thanks for the videos, I've been learning a lot from you. Quick doubt, shoudn't we get the profit from the difference of price and product costs multiplied by the sum of the product sold, and not by the TOTAL (3001) of product sold?. Doing by the TOTAL of product sold, we are not getting the profit by Product but the Total Revenue. Am I Thinking wrongly? Appreciate your videos!!
@yvesflorentwasnyo1299
@yvesflorentwasnyo1299 11 месяцев назад
Thank you very much alex. Please in the second example I have the same results by clicking unit sold without creating a new measure its looks like sum of unit sold already exist in the Apocolypse sales table
@moyosore_nade
@moyosore_nade 6 месяцев назад
In 9:06 , I think why we are using 'Apocalypse Sales' as the table is because Price and Production Cost are already aggregated and populated in all rows but Units Sold is just a row. So we would need to aggregate or iterate it, which is why we are using the table that contains Units Sold. At least, that's how i understand it 🤷🏾‍♂️
@razasaeed5053
@razasaeed5053 4 месяца назад
Hi, I am confused about the example you gave for SUMX. From my understanding, the function subtracts the production cost from the price of each product and multiples it by the total number of units sold (in this case 3001). Shouldn't we multiply by the number of products that sold for each unit. For example Nylon Rope's were sold 390 times and the profit for each nylon rope is $17.32. So wouldn't the total profit for Nylon Ropes be $17.32 x 390 which is $6754.80. The function is mutliplying $17.32 by 3001 which is $51977.32.
@Mikhale.ashford
@Mikhale.ashford 3 месяца назад
Alex is the GOAT 2024
@hoangvu6204
@hoangvu6204 Год назад
Thanks so much Alex, but I think it have a little mistake from your tutorial. About sum and sumx, you use (price - production cost) * amount but each products have another profits so when you multi it have problem.
@gosiafabiszak
@gosiafabiszak Год назад
Alex, are you sure you calculated the SUMx in a correct way? Because it multiplies each row by 3001 so the total number of products sold, not individual for each row. For example, duct tape - 2.75 - 1.01 = 1.74 this is a profit for one duct tape, and then you multipled it by 3001 not 365 so 1.74 * 3001 = 5221.74. Shouldn't it be 1.74 * 365 = 635.1? Please reply because i've spent a lot of time being confused and trying to understand how it works ;)
@baker1853
@baker1853 Год назад
I suppose that in this measure we should use RELATED function - without it we obtain uncorrect result if someone can confirm. Profit = VAR Total_Sales = SUMX ( 'Apocolypse Sales', 'Apocolypse Sales'[Units Sold] * RELATED ( 'Apocolypse Store'[Price] ) ) VAR Total_Cost = SUMX ( 'Apocolypse Sales', 'Apocolypse Sales'[Units Sold] * RELATED ( 'Apocolypse Store'[Production Cost] ) ) VAR Profit = Total_Sales - Total_Cost RETURN Profit
@TheDavesterist
@TheDavesterist Год назад
It looks like it took the sum of all the units sold instead of just the units sold by product id. He made a table of units sold earlier in the video and the sum was 3001.
@pencapchew
@pencapchew 7 месяцев назад
Thank you! I thought I had gone crazy! I looked at the digits and couldn't figure out how on earth the total profits calculated with SUMx got so big! Now we need another video on SUMx, Alex))
@banyalaaabdulganiu1683
@banyalaaabdulganiu1683 Год назад
Hi Alex, quick question, why is the profit distribution along the products different when i use the visualization table instead. note that my viz table consist of product ID, units sold, revenue (a new measure, price * units sold) and then profit( which is also a new measure).
@behzadrezvani6609
@behzadrezvani6609 Год назад
Hi Alex, on the video (9:04), you said we put the Apocolypse Sales because this is the table we are looking at here but actually this is not. this table is Apocolypse Store. Would you explain why you put Apocolypse Sales instead of Apocolypse Store?? Profit_column_SUMX = sumx ('Apocolypse Sales', ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * 'Apocolypse Sales'[Units Sold])
@user-fm4yr2fn8q
@user-fm4yr2fn8q 9 месяцев назад
ya, i spot this error too. Confusing but sad cause he don't reply
@Kaura_Victor
@Kaura_Victor 7 месяцев назад
Thanks, I was confused a little bit.
@alcarajo61
@alcarajo61 3 месяца назад
If you were stuck like me in the Profit colmun => Profit Column = ('Apocolypse Store'[Price]-'Apocolypse Store'[Production Cost])*SUM('Apocolypse Sales'[Units Sold])
@robinfortune2352
@robinfortune2352 2 месяца назад
I am too , the unit sold column ain't coming up
@SkyLoad100
@SkyLoad100 Год назад
May I know what is the difference compare to Tableau?
@mabenba
@mabenba Год назад
They are both tools to deliver the same kind of data products. Here is a nice video of Luke Barousse talking about the differences: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-axgNfM55dw8.html
@BLAXE-vm3ms
@BLAXE-vm3ms Год назад
hey i calculated the value manually for the profit just to cross verify but am getting different values than the one when i use the formula from the video, i am using the exact dataset provided by you and am following the video step by step thoroughly. please do reply if possible
@HoangNguyen-ki8ne
@HoangNguyen-ki8ne Год назад
I think that Sumx in PowerBI is equivalent to the Partition By statement in SQL
@extrov1
@extrov1 4 месяца назад
Hello Alex i tried :TotalProfix = SUMX('Apocolypse Store',('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * ('Apocolypse Sales'[Units Sold])) but still cannot find apocolpyse sales table and giving me this MSG : A single value for column 'Units Sold' in table 'Apocolypse Sales' cannot be determined. This can happen when a measure formula refers to a column that contains many values without specifying an aggregation such as min, max, count, or sum
@shekhaarkanthe4720
@shekhaarkanthe4720 2 месяца назад
hii alex can you create a detailed power bi project video which explains all dax functions
@imamularafat8650
@imamularafat8650 2 месяца назад
Hi Alex, Nice to meet you, Indeed appreciable effort. I had a concern about the DAX chapter profit calculation . But when i was going to address it , i found the same from the other people. By the way, just curious to know why dont you edit the video or make a short video to revise it ? Thanks
@VinodKumar-zn8ty
@VinodKumar-zn8ty Год назад
Hey Alex, For the Sum function columns we took from both sales and store tables. When we are going with the SUMx function you took the table name "Apocalypse Sales", then got the answer as correct. But when I take "Apocalypse Store" as a table in SUMx then the function does not show the 'Apocalypse [units sold]' column. Any reason for selecting a particular table when using these functions Because When we chose the "Apocalypse Sales" table only the 'Apocalypse [units sold]' Column is activated or highlighted in the Function. so, Please clarify me if there is any particular reason behind it.
@saniashehzad9521
@saniashehzad9521 Год назад
I have the same question
@sohrabkhan9590
@sohrabkhan9590 Год назад
Hey, you have to select "Apocalypse Sales" itself, because "Apocalypse Store" doesn't have any tables names "Units Sold".
@houssnachana5709
@houssnachana5709 Год назад
someone knows the answer to this question? I'm trying to understand it too
@guseynguliyev707
@guseynguliyev707 Год назад
I had the same problem but then realised that I should use "Apocolypse Sales" table in the SUMX function, not "Apocolypse Store". This way, I have access to the whole table and can use its columns in the store table.
@TaofiqAdeyemo-uq5no
@TaofiqAdeyemo-uq5no 11 месяцев назад
Learn about the use of RELATED
@BLAXE-vm3ms
@BLAXE-vm3ms Год назад
why did we use apocolypse store in sum function and apocolypse salex in sumx, when we are adding column to the apocolypse store in both?
@ambi297
@ambi297 Месяц назад
can u make more videos on dax
@vp7747
@vp7747 Год назад
Hey Alex, I've just completed my Google DA certificate. I also have a prior 1 yr experience as a Quality Analyst. Can you review my Resume or give any suggestions for seeking a job.
@evelynnakawuka7908
@evelynnakawuka7908 Год назад
Hi Alex, thanks for the videos one question i have is when calculating the profit i get a negative value same for sumx could i be wrong
@chefernandez563
@chefernandez563 Год назад
So there's 2 things wrong with his calculation 1 is the formula structure, the DAX measure is like a calculator ots not recognising that the order of the calculation is not multiplication first, easy way to resolve this is to bracket off the values that are minusing thwn multiply, second issue is that Alex is multiplying by the sum of units for individual rows whixh isn't correct, I am still trying to find a way to solve this😂😂 tearing my hair out but I'm looking into calculation function
@shabihulhasnain1164
@shabihulhasnain1164 5 месяцев назад
Hey Alex, What to do if left function isn’t working on a column and you need to get 7-8 characters from the left of that column in another column. Please Advise
@richflowfunflow
@richflowfunflow 25 дней назад
the sumx function, first part you said "Apocolypse sales" but that table is actually "Apocalypse store", I do not understand... could you explain Alex?
@osiomogieasekome8799
@osiomogieasekome8799 Год назад
Hello..on my y axis instead of units sold i was getting sum of units sold...how do i fix this?
@aularje
@aularje 6 месяцев назад
I am followining your tutorial with Power BI open, and performing all the calculations. Sometimes PBI miscalculates some tables, but then suddenly returns to the correct results, I dont know the causes, but I think is becuse the movement of fields when doing the work
@chefernandez563
@chefernandez563 Год назад
Anyone have a solution ti calculate the individual profits? Cause in this video Alex is multiplying every column by the sum 3001 qhoxh is incorrect
@mahimaparekh6254
@mahimaparekh6254 Год назад
hey.. This is the formula i used Profit Column SUMX = SUMX(RELATEDTABLE('Apocolypse Sales'), 'Apocolypse Sales'[Units Sold] * ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]))
@alcarajo61
@alcarajo61 3 месяца назад
Iluv your videos but using DAX only for count is redundant and the example of SUMX looks great on the video but impossible to do it on PBI :(
@RyfernzOfficial
@RyfernzOfficial 5 месяцев назад
9:00 Hey Alex, I think you made a mistake here... isn't the table we're referring to "Apocalypse Store" and not "Apocalypse Sales"?
@programming02
@programming02 7 месяцев назад
Hello I have question for you when i create visualization table with (product name and profit column ) and (product name and profit column sumx) gave me different answer why this happen?
@Mathswithibraheem
@Mathswithibraheem 6 месяцев назад
Can someone please help me with the correct code for profit and sumx When I run mine my values are incorrect and are in negative Thank you Alex
@afrozaakter5996
@afrozaakter5996 26 дней назад
Hello Alex, Hope you are doing amazing. I am doing your bootcamp and following all the steps. But I got stuck in this video because of PowerBI app. When I wanted to connect the workbook in the powerBI, it shows me this error message 'THERE ARE PENDING CHANGES IN YOUR QUERIES THAT HAVEN’T BEEN APPLIED ' I waited hours and hours but it doesn't load the data. What can I do? Please help me with this?
@rudrapratapsingh1820
@rudrapratapsingh1820 4 дня назад
Guys can anybody tell me at 8:59 why alex used apocalypse sales instead of store because the table were using is store instead of sales?
@user-uq9cv3xe3v
@user-uq9cv3xe3v Месяц назад
Can someone please explain why in the SUMX experession: " Profit_Column_sumX = SUMX( 'Apocolypse Sales', ( ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * 'Apocolypse Sales'[Units Sold] ) )" We used "Apocolypse Sales" in this part ( SUMX(, ))and not "Apocolypse Store", even though we are adding the column to "Apocolypse Store"??
@user-re4ip5ms9w
@user-re4ip5ms9w 2 месяца назад
is it a bad practice that I did this Profit = (SUM('Apocolypse Store'[Price]) - SUM('Apocolypse Store'[Production Cost])) * [Total product sold] instead of this Profit = (SUM('Apocolypse Store'[Price]) - SUM('Apocolypse Store'[Production Cost])) * SUM('Apocolypse Sales'[Units Sold]?
@snoopcat7475
@snoopcat7475 7 месяцев назад
Hey everyone. Hope you all are having a good time learning power BI. I just started the video series and had a doubt regarding the SumX feature. At 9:06 he says, he is applying sumx in the table 'apocalypse sales' so he writes it in the formula, but actually he is applying it in the table 'apocalypse store'. Can anyone explain why he wrote sales instead of store at the beginning of the SumX formula? Or is it just to call in the table into the formula?
@banciuandreea4917
@banciuandreea4917 5 месяцев назад
Profit_Column_SUMx = SUMX('Apocolypse Sales', ('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * 'Apocolypse Sales'[Units Sold]) 1.SUMX('Apocolypse Sales', ...): This part of the formula is using the SUMX function. The SUMX function iterates over each row in the 'Apocolypse Sales' table and performs a specified calculation for each row. 2.('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * 'Apocolypse Sales'[Units Sold]: Inside the SUMX function, this part calculates the profit for each row in the 'Apocolypse Sales' table. It subtracts the production cost from the price for each product (from the 'Apocolypse Store' table) and then multiplies the result by the number of units sold (from the 'Apocolypse Sales' table). 3.Overall Functionality: The SUMX function then adds up the calculated profit for each row, giving you the total profit across all rows in the 'Apocolypse Sales' table.
@chu1452
@chu1452 11 месяцев назад
as a tableau developer, i prefer tableau calculated field tbh
@rachrach9871
@rachrach9871 Год назад
Hi Alex, thank you so much for your tutorial. I actually made it to the last step but the IF statement is giving me an #error on my order_size column and ‘cannot find table ‘big order’ I entered this: IF(‘table name’[Units Sold]>25, ‘Big Order’, ‘Small Order’) Did I miss anything? Like spacing etc? Thank you
@umairkhan7324
@umairkhan7324 9 месяцев назад
You have to use " instead of ' for values.
@esieberhemamoke3817
@esieberhemamoke3817 7 месяцев назад
@@umairkhan7324 Thank you
@esieberhemamoke3817
@esieberhemamoke3817 7 месяцев назад
@@umairkhan7324 Thank you
@mohemami7256
@mohemami7256 4 месяца назад
Alex
@MatheusViniciusFrederico
@MatheusViniciusFrederico 5 месяцев назад
Hey Alex, I was doing the math and the value of the profit per item is WRONG. It is multiplying [price - cost] of the product 10001 by the total of units sold (3001), therefore the value of 59k of profit. The corret value is multiplied by 390 (Total amount sold of the item 10001) which result a total of 6754,8. I tried to fix it in my Power BI but, since I'm learning, I couldn't find a solution. If you ever see this comment or anyone who knows how to fix it, please teach me!
@hasanmougharbel8030
@hasanmougharbel8030 Год назад
Hey there, god bless your efforts in this channel. I have only a simple enquiry as an new sql learner. != Are these two comparison operators mean the same thing in sql syntax? Thanks for taking care of this.
@TRXSTA38
@TRXSTA38 Год назад
Hey, if you take literally the question you asked here and copy paste it to google, you can get an answer instantly instead of waiting for another person to respond. :D
@hosseinrasa3532
@hosseinrasa3532 Месяц назад
hello I Used The Sumx Just LIke The tutorial You'v been learn But The Power Bi Throws An Error About You Cant Use The UnitSold Column Of The Second Dataset May Any One Help Me ??? The Full Error Is : ' single value for column in table cannot be determined. This can happen when a measure formula refers to a column that contains many values without specifying an aggregator such as min, max, count, or sum to get a single result. '
@kiritojuni
@kiritojuni 24 дня назад
Just wonder, have ever reconsile that data ? Because if i got manualy calculate all the transaction value which is (unit sold * price) is all total only 87,945.09. how cold your Dax calculate end up with profit 434,754.87 CMIIW
@gaminggunz8316
@gaminggunz8316 16 дней назад
you're right. profit result value is wrong, can't calculate profit by (sum(all selling prices)-sum(all cost prices) * sum(all units)) because each product has different selling price and cost price. correct method is: for each product = SP-CP * units sold(of that particular product) then sum all these values correct SP = 87945.09 correct CP = 44732.66 correct profit value (SP-CP)= 43212.43
@akintimehinmoromoke
@akintimehinmoromoke 2 месяца назад
Hi Alex, after the getting the Profit.. I placed the customer over the profit but it didn’t split the profit between the customers.. it was showing the total figure in front of all the customers.. What to do anybody😢😢
@mcintyre5328
@mcintyre5328 Год назад
to get count of sales i counted unit sold and got the same answer
@uvbalram2513
@uvbalram2513 10 месяцев назад
Iam unable to download the dataset, can somebody please help me out
@nimrod4463
@nimrod4463 Год назад
Hey, why I can't make the Units Sold By Year and it only does :"Sum of Units Sold By Year", I tried to don't summarize but it didn't help. now it counts it. Please help.
@mikefranko2832
@mikefranko2832 7 месяцев назад
Easier solution: First make a profit column: Profit_column = 'Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost] Second make a Total profit column: Total_profit = 'Apocolypse Store'[Profit_column] * SUM('Apocolypse Sales'[Units Sold])
@sj1795
@sj1795 7 месяцев назад
Wow! This video was packed full of little gems. I really enjoyed learning the difference between SUM and SUMx as well as the IF statement at the end of the video. As always, THANK YOU ALEX!
@abosedetowoju5083
@abosedetowoju5083 Год назад
Here is the profit formula i used but it gave me negative answers like '-200' I don't know if my formula is wrong or ?? Profit = SUM('Apocolypse Store'[Price]) - SUM('Apocolypse Store'[Production Cost]) * SUM('Apocolypse Sales'[Units Sold]). Please let me know the error if you find any. Thanks
@mounirasavadogo1013
@mounirasavadogo1013 Год назад
for anyone having the same problem in the order of operations, multiplication, and division come before addition and subtraction so you have to separate the subtraction from the multiplication with parenthesis Profit = (SUM('Apocolypse Store'[Price]) - SUM('Apocolypse Store'[Production Cost])) * SUM('Apocolypse Sales'[Units Sold])
@esieberhemamoke3817
@esieberhemamoke3817 7 месяцев назад
@@mounirasavadogo1013 Thank you 😊
@JVignesh-bp2jf
@JVignesh-bp2jf Год назад
Hi can anyone show how to do sumX in Excel....? I am unable to get it in Excel..... Please help
@evelynchandia4898
@evelynchandia4898 Год назад
How come am getting a profit as a negative?
@dapoadimula3167
@dapoadimula3167 Год назад
use SUMX('Apocolypse Sales',('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * 'Apocolypse Sales'[Units Sold])
@therrandomguy-ritam9109
@therrandomguy-ritam9109 Год назад
I do not understand why you have used (SUM(Price) - SUM(Productioncost))*SUM(Unitssold). Shouldn't it be SUM((Price - Productioncost)*Unitssold). Cause profit will be different for each product. I believe what you did what calculated entire profit for one unit and multiply it with the total units of all products bought by the customer.
@jf_romo8113
@jf_romo8113 Год назад
I see it in the same way... Product profit depends on number of units sold of each product and not on total number of units sold...
@norebar5848
@norebar5848 Год назад
@@jf_romo8113 You wrote this a long time ago, but I will respond in case someone else has the same question. I made some tests in Excel, and it seems like this RU-vidr has done the math incorrectly. The only way to get the numbers in his table, is if you first take the sum of ALL prices and subtract that by ALL product costs, then multiply by the number of products that the customer bought. This makes zero sense, of course, because the customer did not buy all products, and certainly did not buy the same amount of each product.
@TravisTraps
@TravisTraps Год назад
DAX makes me miss Calculated Functions in Tab.
@vp7747
@vp7747 Год назад
Hey Alex, I think you got a scammer in your chat section. He has replied to mine as well as other’s comments with your display picture and a cell phone number.
@akhouly97
@akhouly97 9 месяцев назад
Hi Alex smth is off here,,,, An accurate example single unit Product selling price: $10 single unit Product manufacturing cost: $5 Units sold: 100 Profit = (10 - 5) * 100 = $500 BUT Sum of Product selling price - sum of Product manufacturing cost multiplied by sum of units is inaccurate (1000 - 500)*100 =$50,000 I got confused for a little bit while following the Video.
@johnn9372
@johnn9372 Год назад
Looks like someone might be taking your videos and putting it on their channel. ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-xvie2jJ9H38.html
@secretnobody6460
@secretnobody6460 8 месяцев назад
im gettinga -5k profit from the formula lmao wtf
@hafizhassan1972
@hafizhassan1972 2 дня назад
your profit comes out to be 43,4754.87 and mine comes out to be 97,778.52 , how? @Alex
@Mathswithibraheem
@Mathswithibraheem 6 месяцев назад
Can someone please help me with the correct code for profit and sumx When I run mine my values are incorrect and are in negative Thank you Alex
@banciuandreea4917
@banciuandreea4917 5 месяцев назад
Profit_Column_SUMx = SUMX('Apocolypse Sales',('Apocolypse Store'[Price] - 'Apocolypse Store'[Production Cost]) * 'Apocolypse Sales'[Units Sold])
Далее
Making DAX Easy
20:01
Просмотров 198 тыс.
Cleaning Data in Excel | Excel Tutorials for Beginners
21:04
What is DAX?
17:48
Просмотров 39 тыс.
EASILY Make an Automated Data Entry Form in Excel
14:52
📊 How to use Power BI DAX - Tutorial
37:28
Просмотров 1 млн