Replies: 4 comments 1 reply
-
You'll need to post some code here so we can try and determine the issue. |
Beta Was this translation helpful? Give feedback.
-
Had the same issue. Seems like CsvReader does not like big files (>2GB). This even happens when trying to parse one by one on the first csvReader.Read(). My suggestion is to split the CSV manually before parsing it |
Beta Was this translation helpful? Give feedback.
-
Sorry. I don't have the exact code anymore because we solved this by created smaller CSVs and send them through csvhelper. But is simply was just the code from the "by hand" example the only differencce was having a csvconfig with custom header-rules, so using a slight different constructor of CSVReader when compared to the example (The other ways importing CSV have the same issue but we just hoped the by-hand-approach would solve the issue. File was about 2GB of Data with 10 Million lines.) Looking at the code:
It already breaks at the first ' csv.Read()' just before the ' csv.ReadHeader()' with the errormessage dpenkova mentioned. I am aware that our file is VERY big. |
Beta Was this translation helpful? Give feedback.
-
Late answer to this, but in my case the reason for this was a wrong Newline-Setting. The CsvReader does not recognize the new line, so assumes the whole file is the Header. And tries to parse all 10GB in my case causing the issue. Not sure if this is the same issue for @dpenkova but worth a look |
Beta Was this translation helpful? Give feedback.
-
I get 'Arithmetic operation resulted in an overflow.' error while trying to read a csv file using csvHepler.
Does anyone have idea how can I solve this?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions