Skip to content

Instantly share code, notes, and snippets.

@gtallen1187
Last active August 29, 2015 14:07
Show Gist options
  • Save gtallen1187/a8196a812e85d7b7aaf8 to your computer and use it in GitHub Desktop.
Save gtallen1187/a8196a812e85d7b7aaf8 to your computer and use it in GitHub Desktop.
find all DB changes within last 5 minutes
SELECT
CONCAT(TABLE_SCHEMA, '.', TABLE_NAME) AS 'Table',
UPDATE_TIME AS 'Updated'
FROM INFORMATION_SCHEMA.TABLES
WHERE DATE_SUB(NOW(), INTERVAL 5 Minute) < UPDATE_TIME AND TABLE_SCHEMA != 'INFORMATION_SCHEMA' AND TABLE_TYPE = 'BASE TABLE'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment