cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Misha Frequent Visitor
Frequent Visitor

Filling with zero values in each cell so they all have the same 4-digit-format

I want to create a link between two tables but therefor onze of the cell's of table 1 should be figured as "0001", "0020"... iso '1", "20"... Anyone that can help me?.. Tx in advance!

 

- in table 1 i have the year '2017' the book "OP" and the documentnummer '1', '20',...

- in table 2 i have the bookingdocument "2017OP0001", "2017OP0020",...

 

I wanted to ad the excelfile and PBI-file but i do not know how to manage that... 😞

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
bccolema Regular Visitor
Regular Visitor

Re: Filling with zero values in each cell so they all have the same 4-digit-format

since you would need to do this is M, you could do something like:

 

=Text.End(000 & [documentnumber], 4)

View solution in original post

Moderator v-yuezhe-msft
Moderator

Re: Filling with zero values in each cell so they all have the same 4-digit-format

@Misha,

You can also create calculated columns using DAX below.

Column = FORMAT(Table[document number],"0000")
Combined column = Table[Year] & Table[Book] & Table[Column]

1.PNG

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
bccolema Regular Visitor
Regular Visitor

Re: Filling with zero values in each cell so they all have the same 4-digit-format

since you would need to do this is M, you could do something like:

 

=Text.End(000 & [documentnumber], 4)

View solution in original post

Moderator v-yuezhe-msft
Moderator

Re: Filling with zero values in each cell so they all have the same 4-digit-format

@Misha,

You can also create calculated columns using DAX below.

Column = FORMAT(Table[document number],"0000")
Combined column = Table[Year] & Table[Book] & Table[Column]

1.PNG

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Exclusive LIVE Community Event #3 – Ask Arun Anything

Exclusive LIVE Community Event #3 – Ask Arun Anything

Join us in the third Triple A event!

Meet the 2020 Season 1 Power BI Super Users!

Meet the 2020 Season 1 Power BI Super Users!

It’s the start of a new Super User season! Learn all about the new Super Users and brand-new tiered recognition system.

January 2020 Community Highlights

January 2020 Community Highlights

Make sure you didn't miss any of the things that happened in the community in January!

Top Solution Authors
Top Kudoed Authors