Skip to content

Commit

Permalink
fix(backend): 修复sql查询大小写问题 #6714
Browse files Browse the repository at this point in the history
  • Loading branch information
iSecloud committed Sep 6, 2024
1 parent 12523ef commit 6786a2b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dbm-ui/backend/core/storages/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def batch_fetch_file_content(self, file_path_list: List[str]) -> List[Dict[str,
file_content_list.append(
{
"path": unzip_file_name,
"content": unzip_files.read(unzip_file_name).decode("utf-8"),
"content": unzip_files.read(unzip_file_name).decode("utf-8", errors="replace"),
"url": self.storage.url(unzip_file_name),
}
)
Expand Down
4 changes: 3 additions & 1 deletion dbm-ui/backend/db_services/mysql/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,6 @@
)

# 根据库名查询表名的sql语句
QUERY_TABLES_FROM_DB_SQL = "select table_schema, table_name from information_schema.tables where {db_sts}"
QUERY_TABLES_FROM_DB_SQL = (
"select table_schema as table_schema, table_name as table_name from information_schema.tables where {db_sts}"
)

0 comments on commit 6786a2b

Please sign in to comment.