![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I am working on Sybase 11.5.1 on Aix 4.2.1 As far as I know it is not possible to get bcp to output data in comma seperated variable length (CSV) format. Is this correct? If it is, are there any utilities which do allow you to bulk extract info out of a Sybase table in CSV format? Preferably freeware one! Any advice / pointers would be appreciated, thanks! Tom. |
#3
| |||
| |||
|
|
"Tom Brehony" <tombrehony.nospam (AT) eircom (DOT) nospam.net> wrote in message news:2np5v8F31umeU1 (AT) uni-berlin (DOT) de... I am working on Sybase 11.5.1 on Aix 4.2.1 As far as I know it is not possible to get bcp to output data in comma seperated variable length (CSV) format. Is this correct? If it is, are there any utilities which do allow you to bulk extract info out of a Sybase table in CSV format? Preferably freeware one! Any advice / pointers would be appreciated, thanks! Tom. Not entirely correct. By specifying the bcp options '-c -t,' you get something that looks very much like a CSV file, with all column values separated by commas. You may need to manually remove the trailing comm (easily done with sed or awk). CSV can actually go a bit further, and quotes a value if it contains a comma itself. Using '-c -t\",\" ' gets quite close. You'd need to put in a leading quote manually (again, use sed or awk). Rob ------------------------------------------------------------- Rob Verschoor Certified Sybase Professional DBA for ASE 12.5/12.0/11.5/11.0 and Replication Server 12.5 Author of Sybase books (order online at www.sypron.nl/shop): "Tips, Tricks & Recipes for Sybase ASE" "The Complete Sybase Replication Server Quick Reference Guide" "The Complete Sybase ASE Quick Reference Guide" mailto:rob (AT) YOUR (DOT) SPAM.sypron.nl.NOT.FOR.ME http://www.sypron.nl Sypron B.V., P.O.Box 10695, 2501HR Den Haag, The Netherlands ------------------------------------------------------------- |
#4
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |