[英]Oracle SQL query to return row values if all rows have some value in column after grouping by another column
[英]Oracle SQL query to return rows that matches a column value having not a digit
我使用以下Oracle SQL查詢列出具有除數字以外的值的列的行。
select * from XXX_ACCOUNTS_20110309 p
where regexp_like (bar_status,'[[^:digit:]]+');
上面的查詢不會返回任何行。
嘗試這個:
where bar_status like '%[^0-9]%'
試試(我無法測試)
select * from XXX_ACCOUNTS_20110309 p
where not regexp_like (bar_status,'[[:digit:]]+');
要么
select * from XXX_ACCOUNTS_20110309 p
where not regexp_like (bar_status,'^[[:digit:]]+$');
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.