Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
abhishek_2593
Advocate I
Advocate I

Need help creating a custom table/summarized table(not a visual) from the existing data

Hi, 

I have a data table which has details of order number, date, tickets, category of tickets and their prices and i need help to create a custom table/summarized table which categorises the ticket counts under each type(as fields from current row details).

 

Can someone please help.

 

Data table sample is as below screenshot

abhishek_2593_0-1736335741824.png

Required Table should be as below

abhishek_2593_1-1736335800518.png

 

Thanks in advance!

 

1 ACCEPTED SOLUTION
123abc
Community Champion
Community Champion

You can try below in Power BI, go to the "Modeling" tab and click on "New Table." Use the following DAX code as an example:

 

NewSummaryTable =
SUMMARIZE(
DataTable,
DataTable[Customer Number],
"Total Tickets", SUM(DataTable[Total Tickets]),
"Paid Tickets", SUM(DataTable[Paid Tickets]),
"Complimentary Tickets", SUM(DataTable[Complimentary Tickets]),
"Adult", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Adult"), DataTable[Tickets]),
"Kids", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Kids"), DataTable[Tickets]),
"Fan Club", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Fan Club"), DataTable[Tickets]),
"Visiting Team", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Visiting Team"), DataTable[Tickets]),
"Players and Club Guests", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Players and Club Guests"), DataTable[Tickets])
)

 

This will generate a summarized table with the breakdown of ticket counts per type for each customer.

View solution in original post

3 REPLIES 3
123abc
Community Champion
Community Champion

You can try below in Power BI, go to the "Modeling" tab and click on "New Table." Use the following DAX code as an example:

 

NewSummaryTable =
SUMMARIZE(
DataTable,
DataTable[Customer Number],
"Total Tickets", SUM(DataTable[Total Tickets]),
"Paid Tickets", SUM(DataTable[Paid Tickets]),
"Complimentary Tickets", SUM(DataTable[Complimentary Tickets]),
"Adult", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Adult"), DataTable[Tickets]),
"Kids", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Kids"), DataTable[Tickets]),
"Fan Club", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Fan Club"), DataTable[Tickets]),
"Visiting Team", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Visiting Team"), DataTable[Tickets]),
"Players and Club Guests", SUMX(FILTER(DataTable, DataTable[Ticket Type] = "Players and Club Guests"), DataTable[Tickets])
)

 

This will generate a summarized table with the breakdown of ticket counts per type for each customer.

Thank you, I'll try this 🙂

Sure ... contacht with me if you have any issue regarding this .

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.