Get the the last ms before tomorrow in Sql Server?
Im using the Between command in mssql server.

I need to find : 

        select * from MyTable where myDate
     between getdate() and [1ms before tomorrow  = 2012-02-26 :23:59:59:999]

*I DONT want [ 2012-02-27 :00:00:00:000] because future queries should use that value .*

*So i need 1 ms before tomorrow.*

However  - this is what ive tried but for some reason it refuse to give me the desire value !
and give me :  `2012-02-26 23:59:59.997` + unpredictable results!

Why is that ? What am i missing ?

I want to get `2012-02-26 :23:59:59:999` !





![enter image description here][1]


  [1]: http://i.stack.imgur.com/6BgGA.jpg
Get the the last ms before tomorrow in Sql Server?
===

Im using the Between command in mssql server.

I need to find : 

        select * from MyTable where myDate
     between getdate() and [1ms before tomorrow  = 2012-02-26 :23:59:59:999]

*I DONT want [ 2012-02-27 :00:00:00:000] because future queries should use that value .*

*So i need 1 ms before tomorrow.*

However  - this is what ive tried but for some reason it refuse to give me the desire value !
and give me :  `2012-02-26 23:59:59.997` + unpredictable results!

Why is that ? What am i missing ?

I want to get `2012-02-26 :23:59:59:999` !





![enter image description here][1]


  [1]: http://i.stack.imgur.com/6BgGA.jpg