PIvoting table around date column in Mysql

前端 未结 1 474
我在风中等你
我在风中等你 2021-01-24 15:12

I am trying to pivot this table

timetableId, assignmentId, dateChecked, hoursWorked
          1,       11,      2017-09-10,     5
          2,       12,      201         


        
1条回答
  •  一向
    一向 (楼主)
    2021-01-24 15:57

    The problem is here:

    case when dateChecked = '10-09-2017'
    

    Use YYYY-MM-DD format for your date comparisons, not MM-DD-YYYY.

    0 讨论(0)
提交回复
热议问题