On 06/27/2013 12:08 PM, Igor Neyman wrote:
> Doesn't have to be hardcoded.
> If executed as dynamic sql, it will be re-planned properly, e.g.:
Well yeah. That's not really the point, though. Aside from existing
code, hard-coding is generally frowned upon. Our devs have been using
CURRENT_DATE and its ilk for over six years now.
So now I get to tell our devs to refactor six years of JAVA code and
find any place they use CURRENT_DATE, and replace it with an ORM
variable for the current date instead.
At this point I wonder why CURRENT_DATE even exists, if using it is
apparently detrimental to query execution.
--
Shaun Thomas
OptionsHouse | 141 W. Jackson Blvd. | Suite 500 | Chicago IL, 60604
312-676-8870
sthomas@optionshouse.com
______________________________________________
See http://www.peak6.com/email_disclaimer/ for terms and conditions related to this email