I want to update a table whenever there is a Null value.
If a column row has a Null value, get the value from first column preceding it, that doesn't have a Null value.
Table1 (before)
q1 q2 q3 q4 ... q50
2 NULL NULL 6 NULL
6 5 NULL NULL NULL
4 NULL 3 NULL 12
Table1 (after)
q1 q2 q3 q4 ... q50
2 2 2 6 6
6 5 5 5 5
4 4 3 3 12
It's tough coding an UPDATE SET stmt for this one.
If a column row has a Null value, get the value from first column preceding it, that doesn't have a Null value.
Table1 (before)
q1 q2 q3 q4 ... q50
2 NULL NULL 6 NULL
6 5 NULL NULL NULL
4 NULL 3 NULL 12
Table1 (after)
q1 q2 q3 q4 ... q50
2 2 2 6 6
6 5 5 5 5
4 4 3 3 12
It's tough coding an UPDATE SET stmt for this one.