sql - ORA-01722: Invalid number in oracle -
i have table called table_temp column amount varchar2(20) executing below query:
select to_number(amount) amt table_temp dc in ('c','d');
result above query
amt ---- 0 123 511 485 0
i want fetch records amt > o , using below query that
select amount amt table_temp dc in ('c','d') , to_number(amount) > 0;
getting error ora-01722: invalid number please suggest me..
if sure rows in table dc in 'c' , 'd' numeric try:
with temp_res (select amount table_temp dc in ('c','d')) select amount amt temp_res to_number(amount) > 0;
Comments
Post a Comment