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 remove spaces between variables using SORT?

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

New User


Joined: 21 Jun 2018
Posts: 7
Location: India

PostPosted: Fri Jul 27, 2018 3:58 pm    Post subject: How to remove spaces between variables using SORT?
Reply with quote

Hi,

I need to remove spaces between variables. There is a possibility that single variable can have spaces in between, it should be removed.

Example:
I have a file which has records like below

123123 |ba12 12|jhajf afdjhsdakj asfdkjhkj |kashfdjhas |

My output should be something like this.

123123|ba12 12|jhajf afdjhsdakj asfdkjhkj|kashfdjhas|.


I have a delimiter as pipe symbol. The record length I am using is 1999, but still I will not get values upto 1999.

Could someone help me asap.

Thanks in advance.

Regards,
Selva N
Back to top
View user's profile Send private message

Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2126
Location: UK

PostPosted: Fri Jul 27, 2018 4:15 pm    Post subject: Reply to: How to remove spaces between variables using SORT?
Reply with quote

What you want to do cannot be done by JCL. JCL does not manipulate data, it simply tells the OS that you want to run a program and the resources needed to do so. It is, also, not a VSAM question. Given those two points, why post in the JCL & VSAM part of the forum.
Topic moved to DFsort part of the forum because it can do what you want. If you do not have DFSort but have SyncSort then let us know and it will be moved to the taht part of the forum.

Look in the manual for something like "Spaces, Removing" in the index and SQZ.
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 2066
Location: NY,USA

PostPosted: Fri Jul 27, 2018 4:48 pm    Post subject:
Reply with quote

Have you even tried once to Google this? If not then please do so since you will get many links and different ways how this is achieved.
Back to top
View user's profile Send private message
Selvarajars

New User


Joined: 21 Jun 2018
Posts: 7
Location: India

PostPosted: Fri Jul 27, 2018 4:51 pm    Post subject: Reply to: How to remove spaces between variables using SORT?
Reply with quote

Hi Nic,

Thanks for your guidance.

I tried with SQZ and it is not working. Can you please help me with the Manual you are referring.

Thanks.

Regards,
Selva N
Back to top
View user's profile Send private message
Rohit Umarjikar

Senior Member


Joined: 21 Sep 2010
Posts: 2066
Location: NY,USA

PostPosted: Fri Jul 27, 2018 4:58 pm    Post subject:
Reply with quote

http://ibmmainframes.com/about65464.html
Back to top
View user's profile Send private message
Selvarajars

New User


Joined: 21 Jun 2018
Posts: 7
Location: India

PostPosted: Fri Jul 27, 2018 5:11 pm    Post subject: Reply to: How to remove spaces between variables using SORT?
Reply with quote

Hi Rohit,

Thanks a lot. Let me try this.

Regards,
Selva N
Back to top
View user's profile Send private message
Arun Raj

Moderator


Joined: 17 Oct 2006
Posts: 2448
Location: @my desk

PostPosted: Fri Jul 27, 2018 6:28 pm    Post subject:
Reply with quote

You might want to take a look at this one.

http://ibmmainframes.com/about47014.html
Back to top
View user's profile Send private message
sergeyken

Active User


Joined: 29 Apr 2008
Posts: 388
Location: Maryland

PostPosted: Fri Jul 27, 2018 10:58 pm    Post subject: Re: Reply to: How to remove spaces between variables using SORT?
Reply with quote

Selvarajars wrote:
Hi Nic,

Thanks for your guidance.

I tried with SQZ and it is not working. Can you please help me with the Manual you are referring.

Thanks.

Regards,
Selva N

In this forum, people usually present their own solution they tried, including:
1) source code
2) input data
3) output data
4) clear explanation of initial requirements, what is wrong, and why?

And next step, they ask for help from the forum.

If there is none of above, you can rarely expect that only the most polite and very kind person would give you a ready-to-use solution.
Mostly the response will be: RTFM!
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 Joining 2 records to 1 using Sort cmuncan DFSORT/ICETOOL 1 Sat Dec 08, 2018 8:53 am
No new posts Calling and updating SAS Macro variab... Yogesh Jaiswal All Other Mainframe Topics 7 Thu Oct 11, 2018 12:37 pm
No new posts Need help on the multiple files refor... wik123 DFSORT/ICETOOL 7 Wed Sep 19, 2018 10:47 am
No new posts Remove selected duplicate rows from t... hnharish DFSORT/ICETOOL 3 Wed Sep 05, 2018 3:11 am
No new posts Sort card to find duplicates, without... anand1204 DFSORT/ICETOOL 15 Fri Aug 31, 2018 12:13 am

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