Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Remove carriage returns from a oracle long field Post Reply Post New Topic
Author Message
djstephens
Newbie
Newbie
Avatar

Joined: 27 Aug 2009
Location: Australia
Online Status: Offline
Posts: 16
Quote djstephens Replybullet Topic: Remove carriage returns from a oracle long field
     Posted: 18 Nov 2009 at 3:22pm
Hi
 
I have extracted data from oracle that includes a long field and thus the field is outputted on many lines  even if field is set to grow.
 
i would like to remove carriage returns and i have done this in excel with the clean function is their a similiar function in crystal
 
 
Dazza
IP IP Logged
hilfy
Admin Group
Admin Group
Avatar

Joined: 20 Nov 2006
Online Status: Offline
Posts: 3702
Quote hilfy Replybullet Posted: 18 Nov 2009 at 5:00pm
You might be able to use Replace and search for the Ascii characters for CR/LF.  Something like this to replace it with a space:
 
Replace({mytable.myfield}, chr(13) + chr(10), ' ')
 
However, depending on which version of Crystal you're using, you may not be able use a field over 255 characters in a formula.  In that case, you can do something similar in a SQL Expression field and have the database remove them before it gets to Crystal.
 
-Dell
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum