We are aware of an issue with the Search bar. Please use Advanced search for the time being while we troubleshoot. Thanks for your patience as we work on improving the community!

Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.

ToNumber Conversion Error

mbangalore
6 - Meteoroid

I am adding two ToNumbers() and want to divide the result by a constant. Can someone help?

 

The statement does not give me the division by 60

 

(ToNumber([Hour1]) + ToNumber([Minute 1])) /60 

3 REPLIES 3
MarqueeCrew
19 - Altair
19 - Altair
1hour + 30minutes do you want the answer to be 1.5 or .52?

If you output to a double you're getting an unrounded version of 31/60.

Try

ToNumber([Hour1]) + ToNumber([Minute 1]))/60

Cheers,

Mark
Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and reboot. Order shall return.
Please Subscribe to my youTube channel.
mbangalore
6 - Meteoroid

I have fields Hour1 and Minute which gives me say 13 Hrs and 45 minutes.

I want to calculate 13+45 / 60 = 58/60 = .96

Thableaus
17 - Castor
17 - Castor

Hi @mbangalore 

 

I tried with two versions, first using RegEX and second only ToNumber function and they worked perfect.

 

2 Solutions.PNG

 

Cheers,

Labels