I am trying to use the .addDay() function but the number of days will be determined by a calculation using several date fields.
I'm getting the following error and don't know how to avoid it.
Mismatch data type for function addDay at argument index 1 expected data type BIGINT found dataType DECIMAL
The code I'm using is as follows:
- request.Date = request.Date.addDay(((request.End_Date - request.Start_Date) / (1000 * 60 * 60 * 24)));
I know there is a function to change a big to decimal but is there one to convert a decimal to a bigint?
Date, End_Date, and Start_Date are all date fields.
I think that the following code is returning a decimal, how can i make this return a bigint?
((request.End_Date - request.Start_Date) / (1000 * 60 * 60 * 24)
)
Thanks