split .csv file using a batch file -


i have huge csv file more columns allowed in excel need split file 2 in order use it.

i found code can put in batch file , works problem if data not available in cell takes data next available cell.
taking long time.
please let me know how code can edited?

@echo off setlocal enabledelayedexpansion rem edit value change name of file needs splitting. include extension. set bfn=bigfile.csv rem edit value change number of lines per file. set lpf=5000 rem edit value change name of each short file. followed number indicating in list. set sfn=splitfile  rem not change beyond line.  set sfx=%bfn:~-3%  set /a linenum=0 set /a filenum=1  /f "delims==" %%l in (%bfn%) (     set /a linenum+=1      echo %%l >> %sfn%!filenum!.%sfx%      if !linenum! equ !lpf! (         set /a linenum=0         set /a filenum+=1     ) ) endlocal pause 

also company not allow me download csv splitters or other data. appreciated.


Comments

Popular posts from this blog

android - Why am I getting the message 'Youractivity.java is not an activity subclass or alias' -

python - How do I create a list index that loops through integers in another list -

c# - “System.Security.Cryptography.CryptographicException: Keyset does not exist” when reading private key from remote machine -