cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
mannu Member
Member

Converting Binary to hex value or numeric value

Hi,

 

I have Hex Value showing up as a Binary content in PBI desktop (ConversationIndex in MSExchange Attribute object)

On expanding this Binary column, I get to see some Unicode characters and not exactly numeric/ hexadecimal values.

 

Is there a way I can convert the Binary content to Hex or interger/ numeric value?

 

Thanks,

Mannu

Mannu
1 ACCEPTED SOLUTION

Accepted Solutions
v-jiascu-msft Super Contributor
Super Contributor

Re: Converting Binary to hex value or numeric value

Hi @mannu,

 

Maybe they aren't hex value or numeric value. You just need a custom column like this.

Binary.ToText([Attributes.ConversationIndex])

Converting_Binary_to_hex_value_or_numeric_value

 

Best Regards,

Dale

Community Support Team _ Dale
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

6 REPLIES 6
v-jiascu-msft Super Contributor
Super Contributor

Re: Converting Binary to hex value or numeric value

Hi @mannu,

 

Please refer to the solution here. You can also try out the demo here.

=List.Accumulate(Text.ToList([ToText]), 0, (state, current)=> state*2 + Number.From(current))

converting_binary_to_hex

 

Best Regards,

Dale

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

Re: Converting Binary to hex value or numeric value

@v-jiascu-msft,
Thank you for the solution Dale. While I can see that the code seems to work for you,
I m unable to get this working with Binary content related with ConversationIndex from MS Exchange data source (MS Exchange -> Mail --> Attributes (expand) and select ConversationIndex.

I see some Unicode characters and nothing else. Unfortunately, I cannot share the PBIX.
Mannu
v-jiascu-msft Super Contributor
Super Contributor

Re: Converting Binary to hex value or numeric value

Hi @mannu,

 

Maybe they aren't hex value or numeric value. You just need a custom column like this.

Binary.ToText([Attributes.ConversationIndex])

Converting_Binary_to_hex_value_or_numeric_value

 

Best Regards,

Dale

Community Support Team _ Dale
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

Re: Converting Binary to hex value or numeric value

@mannu did find a solution? i have same problem....Active Directory objectGUID field is showing is Binary and when i convert it using Binary.ToText..it does not give me original GUID value

flynt1938 Frequent Visitor
Frequent Visitor

Re: Converting Binary to hex value or numeric value

Guid.From(Binary.ToText([Binary],1))

Re: Converting Binary to hex value or numeric value

@flynt1938 i tried this,,,its converting to same format..but thevalue does not match the original value

Helpful resources

Announcements
Can You Solve These Challenge

Challenge: Can You Solve These?

Find out how to participate in the first Power BI 'Can You Solve These?' challenge.

Community News & Announcements

Community News & Announcements

Get your latest community news and announcements.

Virtual Launch Event

Microsoft Business Applications October Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

Community Kudopalooza

Win Power BI Swag with Community Kudopalooza!

Each week, complete activities and be qualified in the drawing for cool Power BI Swag.

Users Online
Currently online: 80 members 1,258 guests
Please welcome our newest community members: