I am parsing an excel and extracting data using which I cam creating a csv file and inserting it as an attachment in salesforce. The problem is with the characters other than english. I am able to read the excel with other character, but when I insert it to salesforce as csv it renders as some junk characters. Here's the code that I am using:
Attachment attach = new Attachment();
Blob body = blob.valueOf('"Initiative","Name","Location"\n"Primary Email","ನಮಸ್ಕಾರಾ","Name12","Currency"');
attach.Body = body;
attach.Name = 'updloadedData.csv';
attach.IsPrivate = false;
attach.ParentId =parentId;
attach.contentType= 'text;charset=UTF-8';
insert attach;
When I recover the csv the kannada (ನಮಸ್ಕಾರಾ) characters get rendered as junk characters. How do I make sure that data is rendered correctly