Loading, please wait...

A to Z Full Forms and Acronyms

Creating Static Table In PowerBI | Deep Dive Into PowerBI

Jul 28, 2020 PowerBI, BusinessIntelligence, 11176 Views
In this Article you will lean how to create Table using DAX function

The previous article of this series was about Steps to Get Previous Row Value from Column. If you want to read the previous article click on the Link

In this article we will learn how to create a static table in PowerBI, guys we need to know why we create static tables in Power BI and what the use of it is. The answer to all your query is sometimes we have to store your data into a new table for comparison with other tables and also want to store some important data into a static table.

Creation of static table in Power BI is just like creating a table in SQL but the difference is only that we use a query for SQL and DAX function for Power BI

Let’s start

Before creating a static table we have to figure out the data type of column according to your needs, we take an example of the student table.

So, student table having 4 columns listed below (see in the picture below)

Name: - string type

Roll_No:- Integer

Class: - string type

Regular: - Boolean

Now create a table in Power BI

Click on New table icon in Table tool ribbon section (see in the picture below)

After click on the new table icon DAX window is a popup, here we have to write DAX function. (See in the picture below)

DAX function for creating table and insertion value into the table.

Student = DATATABLE (
//Defining Columns for a Table
"Name", STRING,
"Roll_No", INTEGER,
"Class", STRING,
"Regular", BOOLEAN,
//Inserting Values to the Columns
{
{ "Ajay",005,"10th",true },
{ "Sonu",007,"11th",false },
{ "Kalu",001,"8th",true },
{ "Ram Singh",010,"12th",false }
})

 

Execute the DAX function by pressing the Enter button on the keyboard, the table is created (see in the picture below)

Finally, plot our data into Table visual (see in the picture below)

This table is very useful in different scenarios and different purposes, also we can use this table into your dashboard for different purposes.

A to Z Full Forms and Acronyms

Related Article