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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
shaebert
Helper III
Helper III

How to create a static index/serial column

Hello. I am looking to create a serial/index column in my table that is easy to reference when processing orders outside of Power BI. 

I have tried adding an index column to my table, but this does not work as the data being entered to the table changes (deleted/modified) from time to time. This left me with the index numbers shifting to different rows. Which made it useless when referencing outside of Power BI.  

I saw someone suggest hardcoding serial/index into the data source, in this case is excel. But this wouldn't work either as rows are automatically added to the data source (excel file). I would have to have a formula that would create an index so it could dynamically populate when rows are automatically added to the spreadsheet.  

I prefer to find a solution in Power BI if possible. And the solution needs to be easily referencable.    

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@shaebert , The best power solution is to add an index column in the power query. If that did not work then you should bring it from the source.

What you are looking is a primary key(incremental id) that can be best done at source.

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@shaebert , The best power solution is to add an index column in the power query. If that did not work then you should bring it from the source.

What you are looking is a primary key(incremental id) that can be best done at source.

Join us as experts from around the world come together to shape the future of data and AI!
At the Microsoft Analytics Community Conference, global leaders and influential voices are stepping up to share their knowledge and help you master the latest in Microsoft Fabric, Copilot, and Purview.
️ November 12th-14th, 2024
 Online Event
Register Here

How can I dynamically do that in excel?

I did some research and found a way to create a dynamic / incremental index/serial column following the formula described here: https://www.thoughtasylum.com/2013/06/29/Auto-Incrementing-in-Excel/

 

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!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.