SELECT
    COUNT(*)
FROM
    sqlite_master
WHERE
    type = 'table'
    AND name = 'migrate_version'
