SELECT MD5(GROUP_CONCAT(definition))
FROM `ohrm_advanced_report`
WHERE unique_name LIKE 'v_pbi_%'
ORDER BY unique_name ASC;

SET @database_name = DATABASE();

SELECT MD5(GROUP_CONCAT(REPLACE(view_definition, @database_name, '')))
FROM information_schema.`VIEWS`
WHERE table_schema = @database_name
  AND table_name LIKE 'v_pbi_%'
ORDER BY table_name ASC;
