This content has been marked as final. Show 10 replies
First of all:
There is no reason to use capitals for the subject line: this is considered shouting.
Secondly: If there is an issue, it is usually version dependent, so you should always post your 4 digit Oracle version.
Finally: we have to guess how you arrived at your issue, as you don't specify which tool you were using, you don't specify the statement in error, and no table definition,
so nobody can reproduce anything.
Senior Oracle DBA
Apology for these silly mistakes as i m not regular on OTN i am not aware of it.
Please find below information:
Oracle version : 18.104.22.168
I am using sqlplus for spooling CLOB data to file.
I have created table named as test with one column with CLOB datatype. That table having one value and a value is mention below:
I am try on both the OS windows as well as in unix but same problem is occurring. Opening clob data from toad or sql developer gives proper CRLF but when i spool it / converting CLOB to TO_CHAR in toad CR gets removed. still unable to trace what is the reason for CR removal from data.
Edited by: user11995332 on Apr 22, 2013 2:44 AM
It is very hard to understand your question, since only you know what you are doing. Would be responders are left guessing.
In particular this seentense give very little meaning to anyone not standing behind you:
Opening clob data from toad or sql developer gives proper CRLF but when i spool it / converting CLOB to TO_CHAR in toad LF gets removedWhich is it, Your subject say CR is removed, still you keep saying LF.?
Spool from where - Is it a Toad spool? - What happens on which OS, how do you determine what happened. Do you move files between Unix and Windows. Is spooled file later opened in Toad. If so how are your settings for "New line format characer data"
This would be minimum effort trying to explain such problem
sqlplus spool file for chr(13)||chr(10).
(Although that is still lacking on the OS part)
Anyway, SY probably answered it. (Guessing that it is CR removed, and not LF)
If this also is the case when spooling to Windows OS, then please demonstrate.
user11995332 wrote:No, the problem occurs using Toad. The clob does not contain the CR!
When i check my string in binary mode i can only find 0A not 0D, but when i save this file using option given in a toad 0A and 0D is coming properly. This problem occurs using sqlplus only. However in toad CRLF is coming properly.
Sql*plus is displaying it as it really is.
Toad is converting the Unix LF to the Windows CR/LF.
If you want the CR added in sql*plus, your could use REPLACE(clob, chr(10), chr(13)||chr(10));