Profit Formula

Sorry for the basic question. I need a row that calculates profit. I have a row titled COGS and a row titled Sold Price and a row titled Profit/Loss. What and how do I add a formula to the Profit/loss row that would calculate that for me? I am SO GRATEFUL for any help!

I tried this formula

=Sales@row - COGS@row

and this is the error code that returned.

Thanks!

Julie

Answers

  • Will Duplex
    Will Duplex ✭✭✭✭✭

    Hi @JulieBerryman. An Unparseable error usually means there's something wrong with the syntax of the formula. In your screenshot above, it seems to be that the first part of your formula is slightly incorrect. Currently, it reads as:

    Sales@row - COGS@row

    But it doesn't look there's a valid reference for the "Sales@row" portion of the formula. Try matching the beginning of your formula to the exact column name that you have above. The output should be:

    Sold Price@row - COGS@row

    Let me know if that works for you!

    💡Did my post help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up/Awesome and/or as the accepted answer. This will make it easier for others to find a solution or help to an answer!

  • Hi @Will Duplex and thank you so much for your help…I truly do appreciate it!

    I tried using

    =Sold Price@row - COGS@row

    and I am receiving the same error code. Is there some formatting I need to do first to row profit/loss?

  • Will Duplex
    Will Duplex ✭✭✭✭✭

    Hello @JulieBerryman. Can you try manually redoing the formula please? Type the "=" sign in the Profit/Loss cell that you're trying to calculate the formula in, and then select the corresponding cell in the "Sold Price" column. At this point, your selection within the "Sold Price" column should be highlighted blue. Then, as you did before add a "-" sign, and then select the cell you want in the "COGS" column. At this point, this selection in your COGS column should be highlighted pink, while still seeing the blue highlight from before. Hitting "enter" should finish the formula and pull a number for you.

    The reason why it may not have done it after your most recent attempt is that column names that contain spaces have to be entered into square brackets. So without manually clicking on the column name, it may have retrieved an error. Smartsheet can do this for you automatically by clicking on the references that you want. (described above)

    The correct formula without redoing the manual clicks would be:

    =[Sold Price]@row - [COGS]@row

    If for some reason you're still getting an "Unparseable" error, ensure that the 3 columns that you're referencing are all set up as a "Text/Number" type.

    💡Did my post help or answer your question or solve your problem? Please support the Community by marking it Insightful/Vote Up/Awesome and/or as the accepted answer. This will make it easier for others to find a solution or help to an answer!

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!