how to distinct a datetime

Discussion in 'Visual Basic ( VB )' started by Harrysuke, Nov 18, 2008.

  1. Harrysuke

    Harrysuke New Member

    Joined:
    Nov 18, 2008
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    0
    can i know how to distinct datetime in sql so that i can populate my combo1.additem from January to December?
     
  2. pradeep

    pradeep Team Leader

    Joined:
    Apr 4, 2005
    Messages:
    1,645
    Likes Received:
    87
    Trophy Points:
    48
    Occupation:
    Programmer
    Location:
    Kolkata, India
    Home Page:
    http://blog.pradeep.net.in
    Code:
    SELECT distinct CONVERT(char,myDate,1) from myDataTable
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice