I want to split the files based on the first column (messageid),
Output file name should be like below
750452173-RE-file1.csv (This file should contain only the same message id)
750464921-RE-file2.csv (This file should contain only the same message id)
750385426-RE-file3.csv (This file should contain only the same message id)
750373470-RE-file4.csv (This file should contain only the same message id)
.
.
Could you please provide the unix command or perl script?
This is not too difficult for the data lines only; did you try anything? If you want to keep the header for each file, additional measures must be taken. Try (and adapt)