Hello, I have a requirement to create a number with 2 decimal points from a string field.
e.g.
'9079' to '90.79'
Also the length of the string is not always the same
any suggestions would be greatfully appreciated
Steve
Résolu ! Accéder à la solution.
Wouldn't the easiest way be to convert the field into a number and then just divide by 100?
Hi, many thanks for that a very easy answer to my problem
regards
steve
Besides the suggestion to give @DataBlender an ACCEPTED SOLUTION, I was wondering about the 2 decimal places. Are you converting 110 to 1.1 or to 1.10? Are you displaying the final result as a string? If you want to display the data, then:
ToString(ToNumber([Amount])/100,2)
If you also want a thousand separator:
ToString(ToNumber([Amount])/100,2,1)
Cheers,
Mark
Hi Mark, no I wanted to convert my string to a number to then store as a currency value in SQL
but many thanks for the reply
regards
Steve