1

i want to insert new line between these two line in db."Asperger's syndrome have difficulty with social interaction and communication.They also have a narrow range of interests." i want my o/p to be like this

'Asperger's syndrome have difficulty with social interaction and communication.
They also have a narrow range of interests.'

insert into ab(column) values ('a'+char(10)+'b');

i tried to insert like this but sql shows error

Error report -

SQL Error: ORA-00936: missing expression 00936. 00000 - "missing expression"
*Cause:

2 Answers 2

5

The operator for string concatenation in Oracle is || and the function name is CHR instead of CHAR.

insert into ab(column) values ('a' || chr(10) || 'b');
Sign up to request clarification or add additional context in comments.

Comments

-1
    insert into ab
  (col1)
values
  (q'[Asperger's syndrome have difficulty with social interaction and communication.]' ||
   chr(13) || 'They also have a narrow range of interests.')

Use the above code for your requirement.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.