I have the following table that records measurements (empty, 1/4, half, 3/4, full) and their date.

```
ID   m1    Time1        m2   time2       m3    Time3       m4   time4
1    half  01/02/2018   3/4  06/06/2018  full  07/06/2018
2    3/4   18/01/2018   full 30/06/2018  
3    full  26/04/2018    
4    1/4   01/02/2018   half 29/06/2018  3/4   01/08/2018  full 03/08/2018 

```

Would it be possible to query the date when the measurement is half to get the following output:

```
ID  time_full
1   01/02/2018
2   NULL
3   NULL
4   29/06/2018

```

Or could we easily transform this longitudinal table into a cross sectional table like this

```
ID  m     time
1   half  01/02/2018
1   3/4   06/06/2018 
1   full  07/06/2018
2   3/4   18/01/2018   
2   full  30/06/2018
3   full  26/04/2018
(...)

```

Thank you