Skip to main content

Posts

Showing posts with the label Power BI

Invoke a stored procedure in SQL server for a given parameter in Power BI

Case- In some cases we need to filter the data that has been imported from a SQL server database where it is not advisable to create a new query all the time. Prerequisite – You need to have a SQL server database where it should contain a two column table with "town-id" and ''town-name'' also you need to create a stored procedure to accept town-id as input parameter and return the town-name as out put.  We are going to run a native query in Power BI with changing parameter values so in order to avoid too many confirmations go to "Files" then "Option and Settings" then "Option" then "Security" then untick Require user approval for new database queries in Power BI. Calling a stored procedure from SQL server when importing data to Power BI As you can see above I have chosen “SQL Server” in the “get data” option from task bar in order to import data from SQL Server database. Then I have given the serve...

Choosing color scheme for Power BI reports

Choosing beautiful colors for an attention seeking Power BI report is always challenging. Sometimes we may have an important message but it might go unseen if proper color scheme is not used, so it is important to create reports which are informational and visually appealing. In this blog our main objective is to get an idea about selecting appropriate color scheme and tools that can be beneficial to do this. What is a color scheme? As you all know not all colors look great together and you can tell stories by just having only two colors, have a look at the following image, there in the middle you can see a circle with same color and same dimension, only thing that changes is the back ground, but depending on the back ground the way you see those circles are totally different. Some small circles appear softer, some appear sharper, and some are brighter also you might notice movements or depth effect too. It is important to choose colors wisely to serve the purp...

R script editor to create an advanced pie chart in Power BI

Case- I want to create a pie chart using R visual in Power BI while being able to use all available features for a creation of pie chart in the programming language R. Creating an R visual In the above image you can notice the symbol R at the bottom of the line, this represents the R visual and I selected it to create one, then I dragged and dropped ProductName and ProductPrice as values for R script. Once you drag and drop a column then the values will be saved as a data frame in the R script of Power BI as shown in the below image. Define the values as ProductPrice and labels as ProductName We can define the values for the pie chart as ProductPrice from the dataset, dataset is the data frame that is predefined when we did the drag and drop in R visual fields. In order to call all the values from a specific column we need to use “$” symbol as shown below “dataset$ProductPrice” Now we need to assign the column values from the data set to the val...