If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > Looking for reference document.

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-21-11, 13:35
blindman blindman is offline
World Class Flame Warrior
 
Join Date: Jun 2003
Location: Ohio
Posts: 11,726
Looking for reference document.

I'm getting an export file of VSAM data from a vendor in what is supposed to be comma-separate format with quoted strings. But the data contains a text field that itself contains quotes, single quotes, commas, carriage returns, etc.
So of course it is not parsing correctly.
Does anyone know of a document online that has accepted standards for forming quoted strings? I would like to be able to point the vendor towards it, so they can generate something I can use.
__________________
If it's not practically useful, then it's practically useless.

blindman
www.chess.com: "sqlblindman"
Reply With Quote
  #2 (permalink)  
Old 07-21-11, 15:34
futurity futurity is offline
Registered User
 
Join Date: May 2008
Posts: 270
RFC 4180 - Common Format and MIME Type for Comma-Separated Values (CSV) Files

Generally, fields containing commas, newlines, or double quotes must be enclosed in double quotes, otherwise they're optional. Double quotes are themselves escaped with another set of double-quotes. However, there really isn't a formal specification, so the exact format may differ, though certainly it should be consistent within a document.
Reply With Quote
  #3 (permalink)  
Old 07-21-11, 16:02
blindman blindman is offline
World Class Flame Warrior
 
Join Date: Jun 2003
Location: Ohio
Posts: 11,726
Excellent.
Bookmarked.

Thanks!
__________________
If it's not practically useful, then it's practically useless.

blindman
www.chess.com: "sqlblindman"
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On