Q:

How can I eliminate duplicate data in column

I would like to eliminate duplicates and show one time
for example
SELECT 'apple, apple, orange'
FROM dual;

I would like to show
apple, orange

as another example.
SELECT 'apple, apple, apple, apple,'
FROM dual;

I just want to show
apple

This code shows
with data as
(
  select 'apple, apple, apple, apple' col from dual
)
select listagg(col, ',') within group(order by 1) col
  from (
        select distinct regexp_substr(col, '[^,]+', 1, level) col
          from data
        connect by level <= regexp_count(col, ',')
       )

A:

Something like this will eliminate duplicates:
SQL Demo
with temp as
(
    select 1 Name, 'test1' Project, 'apple, apple, orange' Error  from dual
    union all
    select 2, 'test2', 'apple, apple, apple, apple,' from dual
), split as (
    select distinct
      t.name, t.project,
      trim(regexp_substr(t.error, '[^,]+', 1, levels.column_value))  as error
    from 
      temp t,
      table(cast(multiset(select level 
                          from dual connect by  level <= length (regexp_replace(t.error, '[^,]+'))  + 1) as sys.OdciNumberList)) levels
)
SELECT Name, listagg(Error, ',') within group(order by 1) as result 
FROM split
GROUP BY Name

OUTPUT
As you can see you get a NULL because that extra comma ,

