Do a search (due date - current date) calculation

Dear Bubblers,

in Custom event i want to calculate number of days lates in Answsers for Q&A apps.

Custom event with Return data :

do a search T_Answers (duedate - curdate) :days :sum.

Result = sum of late answsers.

but it’s not allowed to calculate this basic expression.

Any idea ?

Here the search working in a Table component,

Hi @pva :wave:

What you can do, and I think it will be easier, is to save in your database, how long did it take to the question to be answered.

If you have a question created in 01/01 and it was answered in 01/05, it took 5 days. So you save 5 in your database.

Doing this, you can easily search for your Q&A: each item’s time_to_answer :sum

Thanks for reply,
yes i must do this, all is easy when you have in database .

Also i added 2 fields : 1 late answer ( if curdate >/= event date) , 1 for early answer ( if curdate < event date), to manage answering before event …

Strange Bubble… you can do this in SQL in 1 minute !!!

Regards .