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!

Convert number from text into positive or negative integer

Carl CMay 30 2018 — edited May 30 2018

Hi Guys,

I've this issue with this kind if record.

CRAETE TABLE  TBL1 (COL1 VARCHAR2 (10));

insert into TBL1 values ('+ 1200');

insert into TBL1 values ('+ 2500');

insert into TBL1 values ('-3600');

  

Col 1
+ 1200
+ 2500
- 3600

I must convert into number and keep the result (e.g.) plus 1200 if first char = + and minus (3600) if first char is = -

Thank you in advance if you can help

This post has been answered by Solomon Yakobson on May 30 2018
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 27 2018
Added on May 30 2018
1 comment
1,442 views