Code Duplication    Length = 14-16 lines in 2 locations

src/Phinx/Db/Adapter/MysqlAdapter.php 2 locations

@@ 1095-1110 (lines=16) @@
1092
     * @param string $tableName Table name
1093
     * @return array
1094
     */
1095
    public function describeTable($tableName)
1096
    {
1097
        $options = $this->getOptions();
1098
1099
        // mysql specific
1100
        $sql = sprintf(
1101
            "SELECT *
1102
             FROM information_schema.tables
1103
             WHERE table_schema = '%s'
1104
             AND table_name = '%s'",
1105
            $options['name'],
1106
            $tableName
1107
        );
1108
1109
        return $this->fetchRow($sql);
1110
    }
1111
1112
    /**
1113
     * Returns MySQL column types (inherited and MySQL specified).
@@ 188-201 (lines=14) @@
185
    /**
186
     * {@inheritdoc}
187
     */
188
    public function hasTable($tableName)
189
    {
190
        $options = $this->getOptions();
191
192
        $exists = $this->fetchRow(sprintf(
193
            "SELECT TABLE_NAME
194
            FROM INFORMATION_SCHEMA.TABLES
195
            WHERE TABLE_SCHEMA = '%s' AND TABLE_NAME = '%s'",
196
            $options['name'],
197
            $tableName
198
        ));
199
200
        return !empty($exists);
201
    }
202
203
    /**
204
     * {@inheritdoc}