I’ve got a third party system spitting a CSV file, unfortunatly it appears that sometimes the CSV file include a comma inside a field value like in the address field. “42, Melbourne House”
My constraints are the following :
The third party file format can’t be fixed so I will have to fix it in NAV
I currently use a dataport
So my question is : is there a way to tell the dataport to remove the , in a field value before it identify it as a field separator ?
In addition to TAB separators, they could also use double quotes around all of the fields. These are the FieldStartDelimeter and FieldEndDelimeter properties. Regardless, it’s almost impossible to fix this via code, and if you are you are making judgements about what the data should be. You will have to either fix the file yourself, manually, or have the customer change the way they generate the file. In my experience it usually ends up that you have to do the first.