Terminators are the characters that separate data fields (field terminators). The row terminator is the field terminator of the last field in the table or file. Use the -tfield_terminator and -rrow_terminator command line options with the character format option (-c) to change the terminators from the command line.
The following example uses the comma (,
)
as the field terminator and return (\r) as the row terminator.
In UNIX platforms:
bcp pubs2..publishers out pub_out -c -t , -r \\r
Remember to “escape” the backslash, if necessary, for your operating system command shell.
In Windows NT:
bcp pubs2..publishers out pub_out -c -t , -r \r
This bcp command line produces the following information:
0736,New Age Books,Boston,MA 0877,Binnet & Hardley,Washington,DC 1389,Algodata Infosystems,Berkeley,CA
You can use the -t and -r options to change the default terminators without including the character option (-c).