{"id":893,"date":"2016-01-24T13:50:19","date_gmt":"2016-01-24T03:50:19","guid":{"rendered":"http:\/\/www.moneystock.net\/wp_e\/?p=893"},"modified":"2016-01-24T14:27:37","modified_gmt":"2016-01-24T04:27:37","slug":"csv-library-to-use","status":"publish","type":"post","link":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/","title":{"rendered":"CSV Library to use"},"content":{"rendered":"<p>At first, I used custom built CSV helper class, which simply separates CSV formatted string with a comma and push the data into DataTable. However, this class didn&#8217;t handle double quotation qualifier well enough.<\/p>\n<p>So, I started searching for a CSV library.<\/p>\n<p>One reliable and mostly recommended CSV library was <a href=\"http:\/\/www.codeproject.com\/Articles\/9258\/A-Fast-CSV-Reader\">A Fast CSV Reader<\/a>\u00a0(aka\u00a0<a href=\"http:\/\/nugetmusthaves.com\/Package\/LumenWorks.Framework.IO\">LumenWorks.Framework.IO<\/a>)\u00a0by\u00a0<a href=\"http:\/\/www.codeproject.com\/script\/Membership\/View.aspx?mid=265029\" rel=\"author\">Sebastien Lorion<\/a>, but it&#8217;s not maintained by\u00a0Paul Hatcher in <a href=\"https:\/\/github.com\/phatcher\/CsvReader\">Github Repo<\/a>\u00a0in the name of CsvReader.<\/p>\n<blockquote><p>The <a href=\"https:\/\/www.nuget.org\/packages\/LumenWorksCsvReader\/\">CsvReader<\/a> library is an extended version of Sebastian Lorien&#8217;s <a href=\"http:\/\/www.codeproject.com\/Articles\/9258\/A-Fast-CSV-Reader\">fast CSV Reader<\/a> project and provides fast parsing and reading of CSV files<\/p>\n<p>by &#8211;\u00a0Paul Hatcher<\/p><\/blockquote>\n<p>This was quite good, until I found<\/p>\n<ol>\n<li>CsvReader does not returns the correct row there the CSV format is broken<\/li>\n<li>When there is CR\/LF in the middle of CSV data, this library cannot handle it even though the CR\/LR is wrapped by double quotation qualifier.<\/li>\n<\/ol>\n<p>The next one I&#8217;ve chosen is\u00a0<a href=\"http:\/\/www.csvreader.com\">DataStreams framework<\/a>, which can cope with CR\/LF in CSV data. Unfortunately, this isn&#8217;t open-source. \u00a0I&#8217;m happy with DataStreams up until now.<\/p>\n<p>Hope to find open source CSV libary that is as stable as DataStreams.<\/p>\n<p>Still, I&#8217;m using my first CSVHelper class as a facade \/ wrapper class for these 3rd party library so as to separate the concern as we normally do.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>At first, I used custom built CSV helper class, which simply separates CSV formatted string with a comma and push the data into DataTable. However, this class didn&#8217;t handle double quotation qualifier well enough. So, I started searching for a CSV library. One reliable and mostly recommended CSV library was A Fast CSV Reader\u00a0(aka\u00a0LumenWorks.Framework.IO)\u00a0by\u00a0Sebastien Lorion,&hellip; <a class=\"more-link\" href=\"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/\">Continue reading <span class=\"screen-reader-text\">CSV Library to use<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[203],"tags":[184,95,204,205,208,207,206],"class_list":["post-893","post","type-post","status-publish","format-standard","hentry","category-library","tag-net","tag-c","tag-csv","tag-csv-reader","tag-datastreams","tag-paul-hatcher","tag-sebastien-lorion","entry"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 4.9.8 - aioseo.com -->\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"rocker8942\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 4.9.8\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"Joe&#039;s Happy Life | Be positive, have fun\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"CSV Library to use | Joe&#039;s Happy Life\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2016-01-24T03:50:19+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2016-01-24T04:27:37+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary\" \/>\n\t\t<meta name=\"twitter:title\" content=\"CSV Library to use | Joe&#039;s Happy Life\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#article\",\"name\":\"CSV Library to use | Joe's Happy Life\",\"headline\":\"CSV Library to use\",\"author\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/author\\\/rocker8942\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/#organization\"},\"datePublished\":\"2016-01-24T13:50:19+08:00\",\"dateModified\":\"2016-01-24T14:27:37+08:00\",\"inLanguage\":\"en-US\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#webpage\"},\"articleSection\":\"Library, .Net, c#, CSV, CSV Reader, DataStreams, Paul Hatcher, Sebastien Lorion, English\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/moneystock.net\\\/wp_e\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/#listItem\",\"name\":\"web development\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/#listItem\",\"position\":2,\"name\":\"web development\",\"item\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/library\\\/#listItem\",\"name\":\"Library\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/library\\\/#listItem\",\"position\":3,\"name\":\"Library\",\"item\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/library\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#listItem\",\"name\":\"CSV Library to use\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/#listItem\",\"name\":\"web development\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#listItem\",\"position\":4,\"name\":\"CSV Library to use\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/category\\\/web-development\\\/library\\\/#listItem\",\"name\":\"Library\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/#organization\",\"name\":\"Joe's Happy Life\",\"description\":\"Be positive, have fun\",\"url\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/author\\\/rocker8942\\\/#author\",\"url\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/author\\\/rocker8942\\\/\",\"name\":\"rocker8942\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d00fcc2c7b0eaab40443e28428a4429ab4a95e12086262d902988f448d76b128?s=96&d=mm&r=g\",\"width\":96,\"height\":96,\"caption\":\"rocker8942\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#webpage\",\"url\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/\",\"name\":\"CSV Library to use | Joe's Happy Life\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/2016\\\/01\\\/24\\\/csv-library-to-use\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/author\\\/rocker8942\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/author\\\/rocker8942\\\/#author\"},\"datePublished\":\"2016-01-24T13:50:19+08:00\",\"dateModified\":\"2016-01-24T14:27:37+08:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/#website\",\"url\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/\",\"name\":\"Joe's Happy Life\",\"description\":\"Be positive, have fun\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/moneystock.net\\\/wp_e\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"CSV Library to use | Joe's Happy Life","description":"","canonical_url":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#article","name":"CSV Library to use | Joe's Happy Life","headline":"CSV Library to use","author":{"@id":"https:\/\/moneystock.net\/wp_e\/author\/rocker8942\/#author"},"publisher":{"@id":"https:\/\/moneystock.net\/wp_e\/#organization"},"datePublished":"2016-01-24T13:50:19+08:00","dateModified":"2016-01-24T14:27:37+08:00","inLanguage":"en-US","mainEntityOfPage":{"@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#webpage"},"isPartOf":{"@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#webpage"},"articleSection":"Library, .Net, c#, CSV, CSV Reader, DataStreams, Paul Hatcher, Sebastien Lorion, English"},{"@type":"BreadcrumbList","@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e#listItem","position":1,"name":"Home","item":"https:\/\/moneystock.net\/wp_e","nextItem":{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/#listItem","name":"web development"}},{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/#listItem","position":2,"name":"web development","item":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/","nextItem":{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/library\/#listItem","name":"Library"},"previousItem":{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/library\/#listItem","position":3,"name":"Library","item":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/library\/","nextItem":{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#listItem","name":"CSV Library to use"},"previousItem":{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/#listItem","name":"web development"}},{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#listItem","position":4,"name":"CSV Library to use","previousItem":{"@type":"ListItem","@id":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/library\/#listItem","name":"Library"}}]},{"@type":"Organization","@id":"https:\/\/moneystock.net\/wp_e\/#organization","name":"Joe's Happy Life","description":"Be positive, have fun","url":"https:\/\/moneystock.net\/wp_e\/"},{"@type":"Person","@id":"https:\/\/moneystock.net\/wp_e\/author\/rocker8942\/#author","url":"https:\/\/moneystock.net\/wp_e\/author\/rocker8942\/","name":"rocker8942","image":{"@type":"ImageObject","@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/d00fcc2c7b0eaab40443e28428a4429ab4a95e12086262d902988f448d76b128?s=96&d=mm&r=g","width":96,"height":96,"caption":"rocker8942"}},{"@type":"WebPage","@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#webpage","url":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/","name":"CSV Library to use | Joe's Happy Life","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/moneystock.net\/wp_e\/#website"},"breadcrumb":{"@id":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/#breadcrumblist"},"author":{"@id":"https:\/\/moneystock.net\/wp_e\/author\/rocker8942\/#author"},"creator":{"@id":"https:\/\/moneystock.net\/wp_e\/author\/rocker8942\/#author"},"datePublished":"2016-01-24T13:50:19+08:00","dateModified":"2016-01-24T14:27:37+08:00"},{"@type":"WebSite","@id":"https:\/\/moneystock.net\/wp_e\/#website","url":"https:\/\/moneystock.net\/wp_e\/","name":"Joe's Happy Life","description":"Be positive, have fun","inLanguage":"en-US","publisher":{"@id":"https:\/\/moneystock.net\/wp_e\/#organization"}}]},"og:locale":"en_US","og:site_name":"Joe's Happy Life | Be positive, have fun","og:type":"article","og:title":"CSV Library to use | Joe's Happy Life","og:url":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/","article:published_time":"2016-01-24T03:50:19+00:00","article:modified_time":"2016-01-24T04:27:37+00:00","twitter:card":"summary","twitter:title":"CSV Library to use | Joe's Happy Life"},"aioseo_meta_data":{"post_id":"893","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"Article","isEnabled":true},"graphs":[]},"schema_type":null,"schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"breadcrumb_settings":null,"limit_modified_date":false,"ai":null,"created":"2021-04-24 04:51:00","updated":"2025-06-03 23:48:17","seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/moneystock.net\/wp_e\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/moneystock.net\/wp_e\/category\/web-development\/\" title=\"web development\">web development<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/moneystock.net\/wp_e\/category\/web-development\/library\/\" title=\"Library\">Library<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tCSV Library to use\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/moneystock.net\/wp_e"},{"label":"web development","link":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/"},{"label":"Library","link":"https:\/\/moneystock.net\/wp_e\/category\/web-development\/library\/"},{"label":"CSV Library to use","link":"https:\/\/moneystock.net\/wp_e\/2016\/01\/24\/csv-library-to-use\/"}],"_links":{"self":[{"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/posts\/893","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/comments?post=893"}],"version-history":[{"count":4,"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/posts\/893\/revisions"}],"predecessor-version":[{"id":897,"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/posts\/893\/revisions\/897"}],"wp:attachment":[{"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/media?parent=893"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/categories?post=893"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/moneystock.net\/wp_e\/wp-json\/wp\/v2\/tags?post=893"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}