The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
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.