Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

to_char leading to invalid number error

fbb87bc3-2e3f-46c2-b506-df320d0f02a7Dec 8 2016 — edited Dec 9 2016

Hi,

I have a value say 99.0 in a NUMBER data typed column (value_number).

When I wanted to display it in my front end I am using query

select to_char(value_number) from xxcl_tbl;

this is resulting in invalid number ORA-01722

but if we select the same as like select to_char(99.0) from dual or select to_char('99.0') from dual; are working fine.

P.S : anything other than '0' after the decimal are working fine.

Any thoughts would be highly appreciated. I'm sorry if I am missing any basic funda of SQL.

Cheers,

-- Ram

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 6 2017
Added on Dec 8 2016
7 comments
2,465 views