Skip to content
This repository has been archived by the owner on May 14, 2024. It is now read-only.

Commit

Permalink
Fix case when processing column names for MySQL
Browse files Browse the repository at this point in the history
  • Loading branch information
sdispater committed Oct 10, 2018
1 parent 5537015 commit 1e513d9
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions orator/schema/mysql_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@


class MySQLSchemaBuilder(SchemaBuilder):

def has_table(self, table):
"""
Determine if the given table exists.
Expand Down Expand Up @@ -33,6 +32,12 @@ def get_column_listing(self, table):
database = self._connection.get_database_name()
table = self._connection.get_table_prefix() + table

results = self._connection.select(sql, [database, table])
results = []
for result in self._connection.select(sql, [database, table]):
new_result = {}
for key, value in result.items():
new_result[key.lower()] = value

results.append(new_result)

return self._connection.get_post_processor().process_column_listing(results)

0 comments on commit 1e513d9

Please sign in to comment.