0
点赞
收藏
分享

微信扫一扫

mysql中的dual表

忆北文学摄影爱好员 2022-04-06 阅读 69
mysql


mysql文档中对于dual表的解释:


You are allowed to specify ​​DUAL​​ as a dummy table name in situations where no tables are referenced:

mysql> SELECT 1 + 1 FROM DUAL;
-> 2

​DUAL​​​ is purely for the convenience of people who require that all ​​​SELECT​​​​ statements should have ​​FROM​​​ and possibly other clauses. MySQL may ignore the clauses. MySQL does not require ​​FROM DUAL​​ if no tables are referenced.


举报

相关推荐

0 条评论