Generating a Format File in Sybase ASE BCP
Posted on 2013-10-22
I cannot figure out for the life of my how to generate a format file in a batch file in sybase. I use the following to create my bcp of data file:
bcp mytester.dbo.XTABLE out XTABLE.bcp -U sa -P mypass -T -n
I would think I could do like in sql server:
bcp mytester.dbo.XTABLE format XTABLE.bcp -U sa -P mypass -T -n
bcp mytester.dbo.XTABLE out XTABLE.bcp -U sa -P mypass -T -n -f XTABLE.fmt
but it doesnt seem to work. it seems the only way to do it is in the mode when it prompts me for all details, which is unacceptable for waht I want to do (many tables in a BAT file).
Anyone know how to pull this off?