how to retrive latest date from mysql table

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • selvialagar
    New Member
    • Apr 2008
    • 57

    how to retrive latest date from mysql table

    i have a date field in a table..i want to retrieve the data with latest date...is there any query for that.....
  • debasisdas
    Recognized Expert Expert
    • Dec 2006
    • 8119

    #2
    You want to reteive the row with latest date ?

    Comment

    • amitpatel66
      Recognized Expert Top Contributor
      • Mar 2007
      • 2358

      #3
      Originally posted by selvialagar
      i have a date field in a table..i want to retrieve the data with latest date...is there any query for that.....
      Are you looking at something like:

      [code=mysql]

      SELECT * FROM table_name1 WHERE date_column = (SELECT MAX(date_column ) FROM table_name1);

      [/code]

      Comment

      Working...