I have a column with both data and a null value for a unique PID .
I want to populate the data into my report as
Can anyone please help me to get the SQL for eliminating the null value as specified.
Thanks in advance.
No CASE because you need to work on multiple rows.
If you need additional columns you can utilize ROW_NUMBER:
OVER (PARTITION BY PID ORDER BY VALUE DESC) = 1;