Page 1 of 1

Syncsort hel to sort VB file with different record types

PostPosted: Wed Jan 08, 2014 11:38 am
by vickypunjabi4
Hi

I have a file structure like this

M1C1ARECP
M1C1B______
M1C1C______
M1C1EXXXXX
M1C1ACORR
M1C1B______
M1C1C______
M1C1EXXXXX
M1C1P______
M1C1P______
M1C1ARVRS
M1C1B______
M1C1C______
M1C1EXXXXX
M1C1P______


the 5th byte here i.e. A,B,C E,P here indicate record types.
I want to sort this file based on 6th position to 4 bytes for A type record only, but I want record types to be in same order i.e. A should be first. The file can contain some vales in same position for other record types.
Op should be like this:
M1C1ACORR
M1C1B______
M1C1C______
M1C1EXXXXX
M1C1ARECP
M1C1B______
M1C1C______
M1C1EXXXXX
M1C1P______
M1C1P______
M1C1ARVRS
M1C1B______
M1C1C______
M1C1EXXXXX
M1C1P______

the issue I am facing is that I want A to P records in ascending order based on field of A type record only.

I have a bsic knowledge of Sort not very high level.

I cam eto know that by using these "IFTHEN=(WHEN=GROUP with PUSH" I can solve my issue. Any idea on how can we use this commands in Sort.
Or any other way as well can be really helpful

Please help me
Thanks and Regards
Vicky Punjabi

Re: Syncsort hel to sort VB file with different record types

PostPosted: Wed Jan 08, 2014 2:35 pm
by NicC
Vicky - either you are using DFSort or Syncsort - it is unlikely to be both. Which is it? Look at your sort messages - WER* are Synvcort and ICE* are Dfsort.

Re: Syncsort hel to sort VB file with different record types

PostPosted: Wed Jan 08, 2014 4:20 pm
by vickypunjabi4
NicC wrote:Vicky - either you are using DFSort or Syncsort - it is unlikely to be both. Which is it? Look at your sort messages - WER* are Synvcort and ICE* are Dfsort.



Realy Sorry for this...I posted my topiuc in DFSORT then realized that our System uses SYNCSORT.

My Bad...

Any ways can someone help me

Re: Syncsort hel to sort VB file with different record types

PostPosted: Wed Jan 08, 2014 5:24 pm
by NicC
I will lock this. Your topic on the other forum is in the correct place and is active.