I would like to know whether using the current_date
or get_date()
function on redshift SQL would lower the query performance compared to using '2016-05-05' directly, for example.
Example 1:
select * from table a where time >= current_date - 1 and time < current_date
Example 2:
select * from table a where time >='2016-05-08' and time < '2016-05-09'
Would example 1 or example 2 have better performance? Or would both have the same?
Hope someone could shed some light on it