Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR => "Oracle" to "Mysql" conversion #40

Open
karthikkaruna opened this issue Dec 11, 2018 · 0 comments
Open

ERROR => "Oracle" to "Mysql" conversion #40

karthikkaruna opened this issue Dec 11, 2018 · 0 comments

Comments

@karthikkaruna
Copy link

Hi, I am trying to migrate oracle database to mysql. Oracle has schema defined and As you said i mentioned the schema in two places in ETLAlchemySource.py file

i) At line 899, self.table_names = self.src_insp.get_table_names("SCHEMA")

ii) At line 942, T_src = Table(table_name, MetaData(schema="SCHEMA"))

But when i run the code, errors are thrown at the statement connection.execute() in the file lib/python2.7/dist-packages/sqlalchemy/dialects/oracle/base.by

Please help me to come out this problem.

Below are the errors i got.

ETLAlchemySource (INFO) -
*************************
*** Total Tables: 20 ***
*************************

ETLAlchemySource (INFO) - Reading Table Schema 'students'...
115.111.8.94 - - [11/Dec/2018 07:06:48] "GET /migrate HTTP/1.1" 500 -
Traceback (most recent call last):
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 2309, in call
return self.wsgi_app(environ, start_response)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 2295, in wsgi_app
response = self.handle_exception(e)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 1741, in handle_exception
reraise(exc_type, exc_value, tb)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 2292, in wsgi_app
response = self.full_dispatch_request()
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 1815, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 1718, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 1813, in full_dispatch_request
rv = self.dispatch_request()
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/flask/app.py", line 1799, in dispatch_request
return self.view_functionsrule.endpoint
File "/home/ec-user/omysql/myproject.py", line 14, in migrate
target.migrate()
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/etlalchemy/ETLAlchemyTarget.py", line 86, in migrate
migrate_data=migrate_data)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/etlalchemy/ETLAlchemySource.py", line 944, in migrate
self.src_insp.reflecttable(T_src, None)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/reflection.py", line 563, in reflecttable
table_name, schema, **table.dialect_kwargs):
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/reflection.py", line 369, in get_columns
**kw)
File "", line 2, in get_columns

File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/reflection.py", line 54, in cache
ret = fn(self, con, *args, **kw)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/dialects/oracle/base.py", line 1259, in get_columns
c = connection.execute(sql.text(text), **params)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1991, in execute
return connection.execute(statement, *multiparams, **params)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 914, in execute
return meth(self, multiparams, params)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/sql/elements.py", line 323, in _execute_on_connection
return connection._execute_clauseelement(self, multiparams, params)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1010, in _execute_clauseelement
compiled_sql, distilled_params
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1146, in _execute_context
context)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1344, in _handle_dbapi_exception
util.reraise(*exc_info)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/base.py", line 1139, in _execute_context
context)
File "/home/ec-user/omysql/venv/lib/python2.7/dist-packages/sqlalchemy/engine/default.py", line 450, in do_execute
cursor.execute(statement, parameters)
MemoryError

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant