the reader have written uses dao query database based on parms , returns list of objects list<> . flatfilewrite reason fails unable map field names . further debugging feel write unable accept list or reader sending list> . please let know how handle same .
org.springframework.beans.notreadablepropertyexception: invalid property 'costcenter' of bean class [java.util.arraylist]: bean property 'costcenter' not readable or has invalid getter method: return type of getter match parameter type of setter?
my code same below , xcept reader custom 1 dao , returns list . http://websystique.com/springbatch/spring-batch-read-from-mysql-database-and-write-to-a-csv-file/
you can wrap flatfileitemwriter
in delegating writer unpacks , combines lists passes them on. old answer contains example should work.
Comments
Post a Comment