Flat similar rows on few columns - Oracle
select id, name, customer_code, min(column1), min(column2)
from the_Table
group by id, name, customer_code
order by id;


Note that if there are more rows with non-null columns this would still only return one per combination of id, name and customer_code (but it does return the result in your question)

Edit (after the question was changed)

To get all values for that combination use listagg()

select id, 
       name, 
       customer_code, 
       listagg(column1, ',') within group (order by column1) as col1, 
       listagg(column2, ',') within group (order by column2) as col2
from the_Table
group by id, name, customer_code
order by id;