Multiply date with number

HI folks.
Now Iโ€™ve searched for an hour, so I come to you for help:

I have a DURATION -column (nuber of days) that I want to multiply with a NUMBER -column (KWH power consumption) to get the total consumation of power. Both values are variable so I cannot put a fixed value in for calculation.
It seems like APPSHEET wonโ€™t accept Date-format to multiply with a Nubmer-format in the FORMULA.

Any workaround suggestions?

Solved Solved
0 7 453
1 ACCEPTED SOLUTION

Sorry my typo error, you need to have it like HOUR([Inn1]-[Ut1])/24

View solution in original post

7 REPLIES 7

You need to convert the duration as daysโ€ฆ like ([EndDate]-[StartDate])/24. Then itโ€™s a number and you can use it for your calculation.

Simple, but I diddnโ€™t see it. Big thanks!!

Youโ€™re welcome

Now I feel stupid, but where does date turn into numberโ€ฆ?
I have:
[Date_going out] (Date format) โ€œDateโ€
[Date_going in] (Date format) โ€œDateโ€
[No of days] (Duration format) โ€œ([Date_going in] -[Date_going out])โ€
[Power consumption pr day] (Number format) โ€œGenerated from equipment choiceโ€
[Total consumption] (Number format) โ€œ([Power consumption pr day] * [No of days])โ€

I tried to change it as you wrote in [No of days]
(? format) โ€œ([Date_going in] -[Date_going out])/24โ€

But still it says " Date arithmetic expression (([Inn1]-[Ut1])/24) has an invalid operator"

Sorry my typo error, you need to have it like HOUR([Inn1]-[Ut1])/24

Now it works:)

Excellent!

Top Labels in this Space