Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Inserting String from CSV to mongoDB: add backslashes

Hi, I've developed an ETL job to import data from various CSVs files. So, there's some conversions of data (longs, ints, and per default Strings values).
My problem is, when I saw the data string inserted, have this look:
"prueba" : "\"mate4b\""

And I'm waiting something like:
"prueba" : "mate4b"

There's some config to apply this form?
Thanks in advance guys.
Labels (2)
3 Replies
willm1
Creator
Creator

Have you explored the CSV options on the "Advanced setting" tab of the tFileInputDelimited component, where you can specify escape characters and how to wrap text values?
willm1
Creator
Creator

Typically, the inputdelimited component will read fields from a file as the type you configured in your schema - without the need for explicit conversion. However, you want to do exception handling to make sure you don't try to convert a value into a type that is not allowed (for example, a field contains "1.00"; if you read this in an integer, you'd have an exception; however if you read it in a double, it would be fine.).
_AnonymousUser
Specialist III
Specialist III

You can try using regular expression.