0
A
回答
1
您可以使用IFNULL
SELECT IFNULL(DEV, MUL) as Col FROM myTable -- MySql
SELECT ISNULL(DEV, MUL) as Col FROM myTable -- SQL Server
SELECT NVL(DEV, MUL) as Col FROM myTable -- Oracle
0
0
select * from tablename where (columnname is null)
and
select * from tablename where (columnname1 is null) and (columnname2 is null)
相關問題
- 1. 選擇包含科拉姆值> 1000
- 2. MYSQL總和科拉姆並選擇進行了歸納
- 3. 多重選擇插入1個科拉姆1個結果
- 4. 馬克斯()列中選擇不返回如果科拉姆是空
- 5. MySQL的 - 選擇未知科拉姆WHERE子句
- 6. 從加盟tabels在數據庫中選擇科拉姆笨
- 7. 選擇表格colums從第二科拉姆名字起在MySQL
- 8. 選擇總和(圓(科拉姆,2))在Microsoft Dynamics X ++
- 9. SQL選擇2科拉姆具有相同名稱的2臺
- 10. MYSQL - 在相同的選擇2個值科拉姆
- 11. 未知科拉姆錯誤
- 12. 在科拉姆頭viewgrid
- 13. 使用相同科拉姆
- 14. MySQL的總和基於彼此不同科拉姆一個科拉姆算
- 15. 科拉姆名稱爲數據幀
- 16. 如何在接下來的科拉姆
- 17. 過濾數據幀由科拉姆值與其他2個dataframes
- 18. MySQL的分組方式取決於其他科拉姆值
- 19. XAML STRECH TextBlock的網格科拉姆
- 20. VBA /宏再添科拉姆與條件
- 21. 加入不同colums表單科拉姆
- 22. 科特林生成拉姆達
- 23. 將一個科拉姆圖像在GridView
- 24. JQuery:如果其他選擇下拉
- 25. C#的LINQ加入拉姆達(一鍵選擇包含其它關鍵選擇)
- 26. bash腳本 - 在中間劃分科拉姆2通過科拉姆但保留1和4兩側
- 27. 的try-catch,可選/空,拉姆達
- 28. Ruby on rails:如果已經選擇了值,請避免下拉
- 29. 如何提取新的子字符串作爲科拉姆colums
- 30. 如果已經選擇禁用下拉選項
看看@ http://stackoverflow.com/questions/3952406/select-column-value-if-not-null-else-use-another-column-value 使用IFNULL(b,a)。 –