@IAMSID
I think you are asking two different questions here. In order for the community to help, it would be useful if you gave fo detail around each of your issues. Your example is not clear to me. NOt knowing anything about your source data, what characters are you not expecting?
Providing the following always helps:
1. A dataflow template showing what you have done.
2. Sample input file
3. Desired output file base on above sample
For query 2,
1. How is data being ingested in to NiFi?
2. Configuration of processor components used to ingest data (ConsumeKafka<version>, ConsumeKafkaRecord<version>, recordWriter, etc...)?
3. What other processors does the FlowFile pass through in this dataflow (flow template)?
Thanks,
Matt