Posts

Showing posts with the label PowerBI

Dax calculation Filling Null based on ID column

Dax calculation Filling Null based on ID column  Real Time Problem: I have a table that has two main columns: Account ID and Customer Name. The Customer Name column contains a lot of blanks but the Account ID field is complete, so I was wondering if there's a way to get PowerBI to recognise that Account ID 1 is used against the Customer Name, and therefore to fill in any blanks as a result of this? I know this is really confusing, here's an example:  Name     AccountID John          1 John          1 Null          1 John          1 So is there a way to get PowerBI to recognise that EmpName = Account ID 1, therefore any rows that have the Account ID 1 should fill any blank cells in the Customer Name column with EmpName?   I want these null cells filled so I can use the Customer Name as a Slicer. Solution: Filled_Name =  IF(     ISBLANK('YourTabl...

CONTAINSTRING DAX

Exploring the CONTAINSSTRING Function in DAX Understanding the CONTAINSSTRING Function At its core, the CONTAINSSTRING function enables users to determine whether a specific substring exists within a given text string. This function returns a Boolean value, TRUE if the substring is found, and FALSE if it is not. Here's the basic syntax of the CONTAINSSTRING function: CONTAINSSTRING(<text>, <substring>) <text>: The text string within which you want to search. <substring>: The substring you're searching for within the text. Practical Example: Using CONTAINSSTRING in DAX Let's delve into a practical example to grasp how the CONTAINSSTRING function works within the context of DAX. Suppose we have a dataset containing product information, including a column named ProductName. We're interested in identifying which product names contain the word "apple". We can achieve this by creating a calculated column using the CONTAINSSTRING functi...

Current Month or Current Year or Current Day as a Default Selection

Current Month or Current Year or Current Day as a Default Selection To allow users to always select the current month, year, or day, follow the instructions Dax Example CurrentMonth = IF( 'Calendar Table'[Month] = FORMAT(TODAY(), "mmm"), "CurrentMonth", 'Calendar Table'[Month] ) For the year, simply replace the "Month" column with the "Year" column, and similarly for the day or week, follow the same process. Feel free to ask any questions about Power BI. I am here to help you. Happy Learning! 😊

Power BI Interview Questions & Answers for Freshers

Power BI Interview Questions & Answers for Freshers  1) What is Power BI? Answer: Power BI is a business analytics service by Microsoft that provides interactive visualizations and business intelligence capabilities with an interface simple enough for end-users to create their own reports and dashboards. 2) Explain the components of Power BI. Answer: Power BI consists of three main components: Power BI Desktop (for creating reports and dashboards), Power BI Service (for sharing and collaborating on reports in the cloud), and Power BI Mobile (for accessing reports on mobile devices). 3) What is Power Query? Answer: Power Query is a data connection technology that enables you to discover, connect, combine, and refine data across a wide variety of sources. 4) Explain DAX in Power BI. Answer: DAX (Data Analysis Expressions) is a formula language used in Power BI for creating custom calculations in tables and columns. It is similar to Excel formulas but is designed for use in Power ...