taylorswiftlover Posted September 13, 2019 Report Share Posted September 13, 2019 Hi there! I have a formula in my table, it doesn't seem to work. [@field: A] + [@field: B] So, these are actually text fields. So the values inside are currencies. $100, something like that. How would I be able to add them now? When I use the syntax above, it's only concatenating them. Quote Link to comment Share on other sites More sharing options...
0 Glitch Posted September 13, 2019 Report Share Posted September 13, 2019 Hi Taylorswiftloverdover. I am not sure if this would be the most efficient formula, but this works: CONVERT(FLOAT, (Substring([@field:a], 1, 255))) I don't know, it might be silly. So the substring 1, means that it will be the starting point of the new text, then convert it to number. Works for me, but I know there could've been a better formula Quote Link to comment Share on other sites More sharing options...
0 taylorswiftlover Posted September 13, 2019 Author Report Share Posted September 13, 2019 Thanks Glitchindoodle. I'll try this one. Quote Link to comment Share on other sites More sharing options...
0 ParkLoey Posted March 17, 2021 Report Share Posted March 17, 2021 Hiya there!! I'm sure this one is deeefinitely not the best way to achieve this, but here's how I add my two text fields with a dollar sign '$' + CONVERT(VARCHAR, CONVERT(FLOAT, IsNull(STUFF([@field:Text1],1,1,''), 0)) + CONVERT(FLOAT, IsNull(STUFF([@field:Text2],1,1,''), 0))) I remove the first character, set the DEFAULT value to 0 when it is null, convert them to number, add them, then convert them to text again since I want the result to have a dollar sign too Hope this helps! Quote Link to comment Share on other sites More sharing options...
Question
taylorswiftlover
Hi there!
I have a formula in my table, it doesn't seem to work.
[@field: A] + [@field: B]
So, these are actually text fields.
So the values inside are currencies. $100, something like that.
How would I be able to add them now? When I use the syntax above, it's only concatenating them.
Link to comment
Share on other sites
3 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.