如今,在编写 SQL 查询时流行什么:大写还是小写?
如今,在编写 SQL 查询时流行什么:大写还是小写?又是因为什么具体原因呢?
SELECT * FROM tMyTable
或者
Select * from tMytable
What is POPULAR today when it comes to write SQL Queries: UPPER CASE or Lower Case? And for what specific reason?
SELECT * FROM tMyTable
Or
Select * from tMytable
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
任何一个。 保持一致
个人
...关键字对我来说大写,对象和数据类型采用普通或大写字母。
通过这种方式可以更轻松地挑选出完整 SELECT 查询的子句
Either. Just be consistent
Personally...
Keywords uppercase for me, objects and datatypes in Normal or CapsCase.
It's easier to pick out the clauses of a complete SELECT query this way
对于我来说,这是个人喜好的问题。我更喜欢小写。我不喜欢 sql 语句对我大喊大叫)
As for me, it's a question of personal preferences. i prefer lower case. i don't like when sql-statements shout on me)
在 SQL 语句中,大小写通常并不重要。人们常常将关键词大写只是为了让它们脱颖而出。恕我直言,选择的一致性只会使您的代码更易于阅读,尽管我自己宁愿使用大写的关键字。
Case is not usually important within an SQL statement. Often people capitalise keywords just to make them stand out. IMHO, consistancy of choice just makes your code easier to read, although, I would rather have capitalised keywords, myself.