I have the query
EXEC xp_cmdshell 'bcp "select * from foo.dbo.bar" QUERYOUT "c:\temp\export.csv" -c -t, -T -S'
Which exports fine to that file, but is it possible to break it down so that the first 1000 rows go into export.csv then the next 1000 rows go into export2.csv (etc etc)