IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

How to select two or more columns in a PS file


IBM Mainframe Forums -> HomeWorks & Requests
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
chengaiprabha

New User


Joined: 27 Aug 2008
Posts: 3
Location: India

PostPosted: Sat Sep 20, 2008 3:37 pm
Reply with quote

How we can select two or more columns in a PS file
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Sat Sep 20, 2008 3:53 pm
Reply with quote

Can you please explain what you want to do in detail and maybe then someone will be able to help you.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sat Sep 20, 2008 8:59 pm
Reply with quote

Hello and welcome to the forums,

If you post some sample input and the output you want when that sample input is processed, someone will be able to help.
Back to top
View user's profile Send private message
chengaiprabha

New User


Joined: 27 Aug 2008
Posts: 3
Location: India

PostPosted: Fri Oct 10, 2008 4:18 am
Reply with quote

Hi,

If I have 20 columns and 1000 rows of each(field length) 10 characters length, how we can extract clolumns 1,2,3,6,8,13,16,17,19 and 20 by ordinary edit commands in PS file. Thanks.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Fri Oct 10, 2008 6:05 am
Reply with quote

If you have a COPYBOOK Layout for this file this can be done using DISP ONLY ..

By the way, when you say "extract" here
Quote:
how we can extract clolumns
what exactly does that mean ? Do you want the "extracted" columns in other file or the source file itself be edited..or you want to have a temporary mask on these columns ? Please clarify.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Fri Oct 10, 2008 6:30 am
Reply with quote

Hello,

From part of my earlier reply:
Quote:
post some sample input and the output
You need to post some sample input data and the output you want from that input.

You do not need to post full width or length of the data. Show 5 "columns" and 4 "rows". Show your output as though only columns 2 and 4 were to be extracted.

It is likely that this will be better done using your sort product. Please explain any rules or restrictions as to which tool(s) may be used (or are prohibited).
Back to top
View user's profile Send private message
chengaiprabha

New User


Joined: 27 Aug 2008
Posts: 3
Location: India

PostPosted: Fri Oct 10, 2008 11:16 pm
Reply with quote

Thanks.. Actually 'extract' here I mean is editing within the PS file.
Iam not using any tool here, Just manual edit operations. Some where I read that '(' chracter is used for selection of columns but I want to know
how this could be done. Could you please advise .. Thanks.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Fri Oct 10, 2008 11:23 pm
Reply with quote

Hello,

Which part of "post some sample input and output" was not clear?

As i mentioned before:
Quote:
You do not need to post full width or length of the data. Show 5 "columns" and 4 "rows". Show your output as though only columns 2 and 4 were to be extracted.


Replies other than your sample data will be deleted until you have posted the requested inifo.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> HomeWorks & Requests

 


Similar Topics
Topic Forum Replies
No new posts How to split large record length file... DFSORT/ICETOOL 10
No new posts Extracting Variable decimal numbers f... DFSORT/ICETOOL 17
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts Access to non cataloged VSAM file JCL & VSAM 18
No new posts Need help for File Aid JCL to extract... Compuware & Other Tools 23
Search our Forums:

Back to Top