Please note the 2nd fields are numeric fields so, the in output file it needs to be converted to a 5 digit field ( e.g. 00001) and other will be some fixed length ( e.g in 'batu ' 1 blank spaces added ).
This can be done by a COBOL program.. but I think it can be done in a simple way by using Syncsort..
Joined: 14 Jan 2009 Posts: 37 Topics: 0 Location: USA
Posted: Fri Feb 19, 2010 9:12 am Post subject:
PARSE is not supported in a product as old as SyncSort MVS 3.7 (TPF4). There is no mechanism in SyncSort MVS 3.7 (TPF4) to accompish what you ask. _________________ Brian Wood
SyncSort Mainframe Product Services
201-930-8260
zos_tech@syncsort.com
Joined: 03 Jan 2003 Posts: 1014 Topics: 13 Location: Atlantis
Posted: Fri Feb 19, 2010 11:29 am Post subject:
Failing that, this should be a very straightforward Rexx exec (alloc files, loop with read, parse, reformat write, then free everything). Shouldn't be more than 20 lines or so. If your data is real CSV format though, you also have to account for items that are in quotes in case any fields contain commas. That would add a few lines as a loop since Parse alone will not do that. _________________ New members are encouraged to read the How To Ask Questions The Smart Way FAQ at http://www.catb.org/~esr/faqs/smart-questions.html.
Joined: 03 Jan 2003 Posts: 1014 Topics: 13 Location: Atlantis
Posted: Fri Feb 19, 2010 9:26 pm Post subject:
Its less a question of how big the file is than how often this needs to be done if there are many records. Even if you have a couple million records, this relatively trivial process will finish in a few tens of seconds to a few minutes, but if this runs often, that can be unacceptable. _________________ New members are encouraged to read the How To Ask Questions The Smart Way FAQ at http://www.catb.org/~esr/faqs/smart-questions.html.
HI All,
Thanks for all your comments.. I just mixed this formatting part in my COBOL program by using UNSTRING.. ( For the time being I felt its easier for me )..
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum