Is it possible to scan through every table in a schema for a particular value in Oracle? , small change in the logic , i need to search a specific column (SAMPLE_ABC) in the schema so that i can do research further in which all tables this column SAMPLE_ABC is being used so that i can find the desired result
basically i am searching for a number example column_name - value-12345
i have tried the below but it's running for a very long time ....... , i have tried searching for options but i was not able to
SET SERVEROUTPUT ON SIZE 100000
    DECLARE
      match_count INTEGER;
    BEGIN
      FOR t IN (SELECT owner, table_name, column_name
                  FROM all_tab_columns
                  WHERE owner <> 'SYS' and data_type LIKE '%CHAR%') LOOP
        EXECUTE IMMEDIATE
          'SELECT COUNT(*) FROM ' || t.owner || '.' || t.table_name ||
          ' WHERE '||t.column_name||' = :1'
          INTO match_count
          USING '12345';
        IF match_count > 0 THEN
          dbms_output.put_line( t.table_name ||' '||t.column_name||' '||match_count );
        END IF;
      END LOOP;
    END;
    /
 
    