Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a raw data like this:
Regional | Area |
---|---|
A | AA |
AB | |
AC | |
B | BA |
BB |
I want to fill blank regional column with the value above.
So the record will be like this:
Regional | Area |
---|---|
A | AA |
A | AB |
A | AC |
B | BA |
B | BB |
Is it possible to make it ?
Thanks in advance.
Try like this
IF (len(trim(Regional)) = 0, peek('Regional'), Regional) AS Regional,
Hi Chou,
This is possible but solutions might depend on the data.
Can you please provide more details or your load query and sample data for this?
Is there any condition you have which is making the load on the first column possible or you want it to be random filled?
Thanks and regards,
Sumit
if(regional=null(), above(regional))
use this in script
Try like this
IF (len(trim(Regional)) = 0, peek('Regional'), Regional) AS Regional,
Hi Avinash,
Thank you very much, it solved my problem perfectly.
Glad to help you