Giter VIP home page Giter VIP logo

Comments (11)

Ahoo-Wang avatar Ahoo-Wang commented on May 29, 2024

@fanslead OK,感谢提醒!

:octocat: From gitme Android

from smartcode.

beginor avatar beginor commented on May 29, 2024

pg 数据库建议使用蛇形 (snake_case) 命名规范, 不要区分大小写

from smartcode.

fanslead avatar fanslead commented on May 29, 2024

pg 数据库建议使用蛇形 (snake_case) 命名规范, 不要区分大小写

昨天已经试过这种命名规范,执行sql依旧出现异常,只有用双引号包起来才能执行

from smartcode.

beginor avatar beginor commented on May 29, 2024

@fanslead 可能是列中有关键字吧,要不就是 smart sql 的问题了

from smartcode.

Ahoo-Wang avatar Ahoo-Wang commented on May 29, 2024

@fanslead @beginor SmartSql也只是转发SQL,我猜可能是pg命名的问题。
@fanslead 方便的话给我你的SQL脚本,以便于我今晚复现该问题,并给出修复方案。

from smartcode.

beginor avatar beginor commented on May 29, 2024

@Ahoo-Wang 数据库有问题? 更多的可能应该是 sql 的问题吧

from smartcode.

Ahoo-Wang avatar Ahoo-Wang commented on May 29, 2024

@beginor 命名有可能有问题,就是你刚刚说的啊。

:octocat: From gitme Android

from smartcode.

fanslead avatar fanslead commented on May 29, 2024

@Ahoo-Wang 这是sql脚本,我判断应该是pgsql的命名识别规则的原因。
sql.txt

from smartcode.

Ahoo-Wang avatar Ahoo-Wang commented on May 29, 2024

@fanslead ok,感谢,晚上我来check一下。

from smartcode.

Ahoo-Wang avatar Ahoo-Wang commented on May 29, 2024

@fanslead @beginor

image
image

image

可以看出SQL语句执行是会全部转成小写的,跟ORM是没有关系的。

下面这条是可以执行成功的,因为都是小写。 建议字段名不要使用大写以免造成不必要的麻烦。
image

from smartcode.

fanslead avatar fanslead commented on May 29, 2024

@Ahoo-Wang OK,我把表字段改成纯小写命名吧

from smartcode.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.