The implicit conversion of update_timestamp to small datetime is causing the problem. Use explicit conversion...
WHERE sta_code = 'V'
AND CONVERT(smalldatetime, update_timestamp, style) >= @extract_start_date
...replace style with the correct code, see BOL.
[font="Arial"]“Write the query the simplest way. If through testing it becomes clear that the performance is inadequate, consider alternative query forms.” - Gail Shaw[/font]
For fast, accurate and documented assistance in answering your questions, please read this article
Understanding and using APPLY, (I)[/url] and
(II)[/url] Paul White
Hidden RBAR: Triangular Joins[/url] /
The "Numbers" or "Tally" Table: What it is and how it replaces a loop[/url] Jeff Moden