Custom Search
www.rocket99.com : Technical Guides Sybase Oracle UNIX Javascript


Technical Guides
Sybase
Oracle
UNIX
Javascript




Of Interest

Be responsible for your future
Enter the USA legally!

Visa, Green Card, Citizenship, Passport
Consultation Services








Sybase » UNIX » Commands »

BCP data to/from a flat file

     




/* export */
/apps/sybase/bin/bcp dbname..tablename out /data/data01.bcp -c -Ujsmith -Pyankees -Sserver -I/apps/sybase/interfaces
/* import */
/apps/sybase/bin/bcp dbname..tablename in /data/data01.bcp -c -Ujsmith -Pyankees -Sserver -I/apps/sybase/interfaces


/* BCP table "employee" to file named test1.txt */

/apps/sybase/bin/bcp dev_db..employee out test1.txt -c -t \\t -r \\n
-Sserver -Ujsmith -I/apps/sybase/interfaces

/* BCP file named test2.txt into table employee */

/apps/sybase/bin/bcp dev_db..employee in test2.txt -c -t \\t -r \\n
-Sserver -Ujsmith -I/apps/sybase/interfaces

Parms for each command:

database
table
in/out
character format specified (-c)
tab is the field separator (-t \\t)
newline is the record separator (-r \\n)
server
user
interfaces













Sybase : Related Topics

Sybase : UNIX : Starting the Sybase process
Sybase : UNIX : Running SQL within a script
Sybase : UNIX : Shared memory setting
Sybase : UNIX : Interface Files, IP and Port Translation

Sybase Web Site
Sybase iAnywhere Mobile Web Site
Oracle Enterprise Web Site



Get the latest Rocket99 news and tech tips via






Site Index About this Guide to Sybase, Oracle, and UNIX Contact Us Advertise on this site




Copyright © 2019 Stoltenbar Inc All Rights Reserved.