小编Pau*_*Pau的帖子

如何在SQL oracle中的Select语句中声明空列

我试图在 SELECT 语句中创建 NULL 列,但它不起作用:

SELECT mytable. *, NULL as ColumnName
FROM mytable;
Run Code Online (Sandbox Code Playgroud)

错误代码是

Error report -
SQL Error: ORA-01723: zero-length columns are not allowed
01723. 00000 -  "zero-length columns are not allowed"
*Cause:    Columns with zero length were not allowed.
*Action:   Correct the use of the column.
Run Code Online (Sandbox Code Playgroud)

所以看来不可能这样做。是否可以选择在 SELECT 语句中创建 NULL 列?

谢谢你,

sql oracle null

6
推荐指数
1
解决办法
4915
查看次数

标签 统计

null ×1

oracle ×1

sql ×1