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!

How to insert/update long string into multiple lines

3146284Aug 9 2016 — edited Nov 28 2016

Hi,

Lets take i have table like below.

create table detail_ssi(currency varchar2(10),details varchar2(4000));

now user is going to insert as below(From application)

insert into detail_ssi('USD','hello ds is venky ,working with OFSS ,getting salary to citi bank's account ');

Now my requirement is "hello ds is venky ,working with OFSS ,getting salary to citi bank's account" string should not be inserted as a single line.it should be look like as below with multiple lines.

select * from detail_ssi

-----------------------------------

USD     hello ds is venky ,

            working with OFSS ,

            getting salary to citi bank's account

Note: If we manually insert multiple lines then requirement would be solved but i wanted  if we have insert long string then automatically it should split into multiple lines based any criteria (In my Example it can be ','(comma))

How can i achieve above requirement either using SQl/PLSQL ?

Regards

Venky

This post has been answered by Gaz in Oz on Aug 9 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 26 2016
Added on Aug 9 2016
6 comments
5,415 views