Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
How to insert a Apostrophe using OUTREC

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
Swami-gs

New User


Joined: 27 Apr 2007
Posts: 20
Location: Chennai

PostPosted: Fri Aug 17, 2007 5:14 pm    Post subject: How to insert a Apostrophe using OUTREC
Reply with quote

How to insert a Apostophe using OUTREC.

I want to insert a string in a File in certain position.
I want to insert a string namely "sam's". This particular string has a apostophe in it. Normally if I try like this

OUTREC FIELDS=(1:C'SAM'S',
....
.....


It would throw a error since it encountered a apostophe already.

So, how to insert using OUTREC?
Back to top
View user's profile Send private message

saiprasadh

Active User


Joined: 20 Sep 2006
Posts: 154
Location: US

PostPosted: Fri Aug 17, 2007 5:35 pm    Post subject:
Reply with quote

Hi Swami

Use the below Sort Card

Code:
OUTREC FIELDS=(1:C'SAI',4:C'''S',.....)

Thanks
Sai
Back to top
View user's profile Send private message
Swami-gs

New User


Joined: 27 Apr 2007
Posts: 20
Location: Chennai

PostPosted: Fri Aug 17, 2007 6:18 pm    Post subject:
Reply with quote

Hi Sai

Thanks for your info.

it works fine.
Back to top
View user's profile Send private message
Frank Yaeger

DFSORT Moderator


Joined: 15 Feb 2005
Posts: 7130
Location: San Jose, CA

PostPosted: Fri Aug 17, 2007 8:39 pm    Post subject:
Reply with quote

Quote:
it works fine.


Well, yes, but Sai's solution is more complicated than it needs to be. You just need to use two apostrophes for each one apostrophe. So it would just be:

Code:

    OUTREC FIELDS=(1:C'SAM''S',...)
Back to top
View user's profile Send private message
Swami-gs

New User


Joined: 27 Apr 2007
Posts: 20
Location: Chennai

PostPosted: Thu Aug 23, 2007 8:44 pm    Post subject:
Reply with quote

Thanks Frank,

Finally after a long trial and error method on what Sai said. I finally got the idea which you told now. Anyway thanks !!!
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts OUTREC OVERLAY different to INCREC ge... Joerg.Findeisen SYNCSORT 8 Fri Apr 27, 2018 2:11 am
No new posts OUTREC with ALter Command scorp_rahul23 DFSORT/ICETOOL 1 Wed Nov 22, 2017 3:10 pm
No new posts How to insert a value on specific pos... Poha Eater DFSORT/ICETOOL 9 Sun Oct 01, 2017 3:04 am
No new posts Insert a Row_number into table useit DB2 2 Tue Sep 19, 2017 1:07 pm
No new posts WER268A OUTREC STATEMENT : SYNTAX E... frozenblood87 SYNCSORT 12 Sat Aug 26, 2017 9:45 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us