I want to comment 2 lines based on a condition. If THEN occurs immediately after WHEN then i have to comment both the lunes
For example :
$cat file1.txt
CASE
WHEN
THEN 1
WHEN
c1= 'I'
AND c2= '0'
THEN 2
So in this example i want to comment the lines as shown below.
SO the required output :
$cat file1.txt
CASE
# WHEN
# THEN 1
WHEN
c1= 'I'
AND c2= '0'
THEN 2