【问题标题】:Prisma Unsupported("point") MySql ApproachPrisma Unsupported("point") MySql 方法
【发布时间】:2021-10-29 09:52:22
【问题描述】:

所以我的 location 列使用 Point 数据类型,我使用的是 Apollo Server 和 Prisma,当我使用“npx prisma db pull”时生成此数据类型,因为当前不是支持 Prisma (generated script)

所以我说“好的,我正在使用字符串并且我管理如何插入这种数据类型”所以我改为this script,惊喜!没有工作enter image description here,尝试找到任何方法来处理 Prisma 中的 MySql Point 数据类型,但没有任何信息,我真的很感激任何想法

【问题讨论】:

  • 请提供足够的代码,以便其他人更好地理解或重现问题。

标签: mysql orm prisma


【解决方案1】:

您不能将其转换为 String 并像 isn't supported yet 一样使用它。您需要将其保留为不受支持,您只能通过raw queries 添加数据。

目前,仅支持添加数据。您不能使用PrismaClient 查询它。

【讨论】:

    猜你喜欢
    • 2023-03-03
    • 2022-11-18
    • 1970-01-01
    • 2022-08-04
    • 1970-01-01
    • 2012-05-15
    • 2017-06-19
    • 1970-01-01
    • 2020-10-25
    相关资源
    最近更新 更多