Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

logging bcp errors

Status
Not open for further replies.

fgeorge

Programmer
Jun 28, 2002
76
NG
i am using bcp to load several text files into a table..
i understand that 4 for several reasons, my text files may not be loaded..
i how can i log these errors into another table if loading fails..
for example , i may want to put the first item in the tx file in another table plus a flag in the next field of my errors table which says that the bcp failed..with an error message possibly..
thanks
 
bcp [[database_name.]owner.]table_name {in | out} datafile
[/m maxerrors] [/f formatfile] [/e errfile]
[/F firstrow] [/L lastrow] [/b batchsize]
[/n] [/c] [/E]
[/t field_term] [/r row_term]
[/i inputfile] [/o outputfile]
/U login_id [/P password] [/S servername] [/v] [/a packet_size]


just create a error file using the /e filename
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top