6 Replies Latest reply on Mar 6, 2016 10:10 PM by Tharashasank Davuluru

    Converting String to Date (Year) is giving me trouble

    Aditya Balgi
      TitleYearAvg. Rating
      2 Fast 2 Furious (Fast and the Furious 2, The) (2003)20032.666666667
      2 Days in Paris (2007)20073.3
      2 Days in the Valley (1996)19963.5

       

      Hello,

       

      The above table is what my data looks like, here is the calculation i used to extract Year from Title  MID([Title],LEN([Title])-4,4)

       

      but i am unable to sort by Year because  it is a calculated field  of String data type (Correct me if i'm wrong)

       

       

       

      So i tried converting the Year field to Date using   DATE(MID([Title],LEN([Title])-4,4))   but it changed all my Year fields to Nul

       

      TitleYearAvg. Rating
      2 Fast 2 Furious (Fast and the Furious 2, The) (2003)2.666666667
      2 Days in Paris (2007)3.3
      2 Days in the Valley (1996)3.5

       

       

      How do i sort on the Year column? I want the newest movies on top