Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello,
I have a column that contains username and employee code all stored in format 'Text'. I wish to separate username and employee code to different column so that I can build relation to another datasets.
Username are all characters and employee codes are all digits.
Could you help me how to achieve?
Sample data? Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490
Adding Sample data,
Data,
Login IDs |
abc |
def |
ghi |
123 |
456 |
789 |
jkl |
987 |
654 |
mno |
pqr |
Expected Outcome.
Login IDs | Username | Employee Code |
abc | abc | null |
def | def | null |
ghi | ghi | null |
123 | null | 123 |
456 | null | 456 |
789 | null | 789 |
jkl | jkl | null |
987 | null | 987 |
654 | null | 654 |
mno | mno | null |
pqr | pqr | null |
Previous recommended action,
Hope this helps to understand the query.
Can you check the below link
To get null values you have define it in add custom columns.
Proud to be a Super User! | |
In power Query , we have option in transform tab with split column there can you can segregate by Nondigit to Digit.
Just check the option we can seperate both text data and digit data with seperate column.
if it clears the problem Please mark it as solution.
Thanks
Proud to be a Super User! | |
thanks @rajendraongole1
tried with this formula
= Table.SplitColumn(#"Renamed Columns1", "LOGIN ID", Splitter.SplitTextByCharacterTransition({"0".."9"}, (c) => not List.Contains({"0".."9"}, c)), {"LOGIN ID.1", "LOGIN ID.2"})
but the result for LOGIN ID.2 is null completely.
Presume it could be because username are all charaters and employee code are all digits?
Note : the Entire column is in Text Format.
User | Count |
---|---|
75 | |
75 | |
45 | |
31 | |
27 |
User | Count |
---|---|
99 | |
89 | |
52 | |
48 | |
46 |