Use case

Return the duration between the current date and the due date of the current issue in days.

Expression

Create and configure a Smart field using this expression in General mode:

%{{issue.dueDate} != null ? max({issue.dueDate} - {system.currentDateTime}, 0) / DAY : null}

If the resulting number from the expression contains too many decimal numbers, feel free to select one of the available display formats or to configure it manually.

Used parser functions