Untitled

mail@pastecode.io avatar
unknown
plain_text
7 months ago
656 B
7
Indexable
Never
SELECT table_name, column_name
FROM information_schema.columns
WHERE table_schema = 'core'
  AND table_name IN (SELECT table_name FROM information_schema.tables WHERE table_schema = 'core')
  AND CONCAT(table_name, '.', column_name) IN (
    SELECT CONCAT(table_name, '.', column_name)
    FROM information_schema.columns
    WHERE table_schema = 'core'
      AND table_name IN (SELECT table_name FROM information_schema.tables WHERE table_schema = 'core')
      AND table_name IS NOT NULL
      AND column_name IS NOT NULL
      AND (
        SELECT COUNT(*)
        FROM your_database_name.table_name
        WHERE column_name = '287643'
      ) > 0
  );
Leave a Comment