Remember to account for the RDW (positions 1-4) when determining the starting position (p).
I have tried above suggestion, but got L(12) error.
from the manual, it says the input file is not in sequence, I can confirm
the record already sorted by the Key.
If the records are sorted by the key, but you got an "input file is not in sequence error", then you didn't specify the key correctly in the SORT statement. My first guess would be that you didn't account for the RDW when determining the starting position. Try adding 4 to the starting position. If that doesn't work, you'll have to supply more information about how the VSAM file is defined, the SORT statement you used, etc before we can help any further.
When we sort VB QSAM to VB VSAM file, the RDW part can be written to VSAM 1st 4 bytes ?
I'm not sure what you're asking here. Are you asking if DFSORT normally writes the RDW to the VSAM records or the RDW can be written or not written to the VSAM record?