MySQL到PostgreSQL迁移将骆驼栏转换为简单格式。导致列中不存在Django Orm中的错误

发布于 2025-02-07 02:40:19 字数 183 浏览 1 评论 0原文

我使用PGLOADER迁移MySQL数据库到PostgreSQL。我正在使用django orm执行查询。数据库字段是在骆驼案中定义的,但是在迁移后,Postgres列被替换为正常格式。例如,Brochurename更改为Brochurename。这导致应用程序中的“不存在”错误。 处理此问题的最佳方法是什么?在许多情况下,我已经定义了很多列和查询。

I migrated MySQL database to PostgreSQL using pgloader. I am using Django ORM to execute the queries. The database fields are defined in camel case but after the migration the postgres columns are replaced to normal format. e.g brochureName is changed to brochurename. This is causing "Column does not exist" error in the application.
What is the best way to handle this issue? I have lots of columns and queries already defined at many instances.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

暮凉 2025-02-14 02:40:19

您可以将其与一起使用引用标识符

LOAD database
    from mysql://
    into postgresql://
WITH quote identifiers

You can use it with WITH quote identifiers

LOAD database
    from mysql://
    into postgresql://
WITH quote identifiers
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文