Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Is it possible to do these three things in the process of creating a table?
I'm new to DAX and can't decide if I can attack these 3 issues in a single formula.
Scenario simplified:
Let's say I have a table called "Projects" with 3 columns: Project ID, Project Name, Start Date.
I'd like to:
1. Create a separate table based on specific columns. So I'd only need the Project Name and Start Date column.
2. Rename these columns so that instead of it saying Project Name and Start Date, let it say Project, Start
3. Filter only Projects from >=2020 year. (The date is in the format 1/1/2020)
Can I achieve all three in a formula when creating the table?
Here's my attempt:
New Table = SELECTCOLUMNS ( "Project", 'Projects'[Project Name], "Start", 'Projects'[Start Date], )
How can I apply the filter here? With an IF statement? With Return or some sort of calculation formula?
Solved! Go to Solution.
Hi,
give this a try:
SELECTCOLUMNS(
FILTER(Projects, Projects[Start Date] >= DATE(2020,1,1)),
"Project",Projects[Project Name],
"Start",Projects[Start Date]
)
Regards FrankAT
Hi,
You can do the same using Power Query. Try applying the below steps:
1- Click on Edit Query
2- Select the Query/Table you want to replicate
3- Right click on the query and select Reference
4- Manipulate the new query by changing the column names and filter the date
Hi,
give this a try:
SELECTCOLUMNS(
FILTER(Projects, Projects[Start Date] >= DATE(2020,1,1)),
"Project",Projects[Project Name],
"Start",Projects[Start Date]
)
Regards FrankAT
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
73 | |
71 | |
54 | |
38 | |
31 |
User | Count |
---|---|
71 | |
64 | |
60 | |
50 | |
45 |