If the actual year (2019) contains 1 month (since we are in January), then show me the sum of sales for 1 month of the last year (2018). Otherwise show me the total sum of sales for 2018 (in the case that 2019 is over).
Which one month of 2018? Dec or Jan? or any random month?
And when you say show total? what exactly do you have as dimension here? Month or what? and that is why asked for an example (some raw data and the expected output from it).