Bug #93785 Migration: Reverse engineer selected schemas fails
Submitted: 2 Jan 14:23 Modified: 2 Jan 14:53
Reporter: Jamie hutber Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Workbench: Migration Severity:S3 (Non-critical)
Version:8.0.13/8.0.15 OS:Ubuntu (18.04)
Assigned to: CPU Architecture:Any

[2 Jan 14:23] Jamie hutber
Description:
An attempted migration failed at the "Reverse Engineer Source" step, during "Reverse engineer selected schemas".

Starting...
Connect to source DBMS...
- Connecting...
Connecting to postgresql@DRIVER=psqlODBC;SERVER=127.0.0.1;PORT=5432...
Opening ODBC connection to DRIVER=psqlODBC;SERVER=127.0.0.1;PORT=5432;DATABASE=depotdb;UID=postgres;UseDeclareFetch=1;...
Connected
Connect to source DBMS done
Reverse engineer selected schemas....
Reverse engineering production_status from depotdb
- Reverse engineering catalog information
Traceback (most recent call last):
  File "/usr/lib/mysql-workbench/modules/db_postgresql_re_grt.py", line 356, in reverseEngineer
    return PostgresqlReverseEngineering.reverseEngineer(connection, catalog_name, schemata_list, context)
  File "/usr/lib/mysql-workbench/modules/db_generic_re_grt.py", line 241, in reverseEngineer
    catalog = cls.reverseEngineerCatalog(connection, catalog_name)
  File "/usr/lib/mysql-workbench/modules/db_generic_re_grt.py", line 401, in reverseEngineerCatalog
    cls.reverseEngineerSequences(connection, schema)
  File "/usr/lib/mysql-workbench/modules/db_postgresql_re_grt.py", line 80, in reverseEngineerSequences
    min_value, max_value, start_value, increment_by, last_value, is_cycled, ncache = cls.execute_query(connection, seq_details_query % (schema.name, seq_name)).fetchone()
  File "/usr/lib/mysql-workbench/modules/db_generic_re_grt.py", line 80, in execute_query
    return cls.get_connection(connection_object).cursor().execute(query, *args, **kwargs)
pyodbc.ProgrammingError: ('42703', '[42703] ERROR: column "min_value" does not exist;\nError while executing the query (1) (SQLExecDirectW)')

Traceback (most recent call last):
  File "/usr/share/mysql-workbench/libraries/workbench/wizard_progress_page_widget.py", line 196, in thread_work
    self.func()
  File "/usr/lib/mysql-workbench/modules/migration_schema_selection.py", line 179, in task_reveng
    self.main.plan.migrationSource.reverseEngineer()
  File "/usr/lib/mysql-workbench/modules/migration.py", line 364, in reverseEngineer
    self.state.sourceCatalog = self._rev_eng_module.reverseEngineer(self.connection, self.selectedCatalogName, self.selectedSchemataNames, self.state.applicationData)
SystemError: ProgrammingError("('42703', '[42703] ERROR: column "min_value" does not exist;\nError while executing the query (1) (SQLExecDirectW)')"): error calling Python module function DbPostgresqlRE.reverseEngineer
ERROR: Reverse engineer selected schemas: ProgrammingError("('42703', '[42703] ERROR: column "min_value" does not exist;\nError while executing the query (1) (SQLExecDirectW)')"): error calling Python module function DbPostgresqlRE.reverseEngineer
Failed

How to repeat:
Install mysql `mysql  Ver 14.14 Distrib 5.7.24, for Linux (x86_64) using  EditLine wrapper`
Install psql `psql (PostgreSQL) 10.6 (Ubuntu 10.6-0ubuntu0.18.04.1)`
Install psql drive for mysql workbench as described: https://dev.mysql.com/doc/workbench/en/wb-migration-database-postgresql-drivers-linux.html
[2 Jan 14:53] Miguel Solorzano
Thank you for the bug report. Duplicate of https://bugs.mysql.com/bug.php?id=93594
[19 Feb 22:44] Miguel Solorzano
https://bugs.mysql.com/bug.php?id=94399 marked as duplicate of this one.