SQL Enterprise not updating table

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Joell
    New Member
    • Aug 2007
    • 31

    #16
    Originally posted by ck9663
    because your c_quote are all 2007-09-14 dates and getdate() is 2007-09-17. getdate(), in this example, is greater than 2007-09-17, hence no result set are returned.
    I was using c_quote >= getdate() -1


    The query is supposed to run at 5am so I do not know if it will work correctly until tomorrow but I think this might work:

    c_quote >= convert(datetim e,convert(varch ar,getdate(),10 1)) -1

    Thanks for your efforts!

    Comment

    • Dosth
      New Member
      • Nov 2007
      • 1

      #17
      try this

      convert(varchar (10),c_quote,10 1) >= convert(varchar (10),getdate()-1,101)

      Thanks
      Dosth

      Comment

      Working...