Hi, I want to read a csv file from the file directory into a java bean, do some work on the data (a List) and then save the data to a new csv file.
I mange to do the first part (unmarshal) , but I don't know how to do the part of writing the file after I finished my work on it (marshal ). Here is my code , but I get en exception on the marshal part : "can not convert from a String to a Map" <bean id="csvReportsHandler" scope="singleton" class="calypsox.reports.CsvReportsHandler" /> <camelContext xmlns="http://camel.apache.org/schema/spring" id="report1"> <propertyPlaceholder id="reportsProperty" location="BLLresources/reports.properties" /> <route> <from uri="file:{{report1.incoming.directory}}?preMove={{report1.inprogress.directory}}&move= {{report1.done.directory}}&moveFailed={{report1.failed.directory}}" /> <unmarshal> <csv /> </unmarshal> <to uri="bean:csvReportsHandler?method=doHandleCsvData" /> <marshal> <csv /> </marshal> <to uri="file:{{report1.outcoming.directory}}?fileName=teat.csv" /> </route> </camelContext> Can you help ? Thx -- View this message in context: http://camel.465427.n5.nabble.com/writing-a-csv-file-tp5745260.html Sent from the Camel - Users mailing list archive at Nabble.com.