Click here to Skip to main content
15,886,030 members
Please Sign up or sign in to vote.
2.50/5 (2 votes)
See more:
hello every body ...
I'm working on a java-oracle program , I have an oracle function that returns a clob which is the result of appending a group of Strings (of type nvarchar2) ...
in oracle function I'm separating values using CHR(10) to make a new line , check this

'a' || chr(10) || 'b'

this works in oracle , I mean it looks like

a
b

But in my java application when I retrieve this value returned from oracle function it appears

ab

does anyone have any idea about what to do to make a new line ?
Posted
Comments
DaveAuld 10-Oct-12 12:08pm    
\n ?
[no name] 10-Oct-12 16:12pm    
Not long enough to be a solution?

1 solution

What's your environment?
If it's windows you'll need to use 'a' || chr(13) || chr(10) || 'b'.

chr(13) is carriage return (CR) and chr(10) is linefeed (LF).
In a unix system chr(10) is enough, while on windows you need both CR and LF.
To make it more fun you used just CR on Mac OS up to version 9
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900