Hi,
In JdbcCursorItemReader, we have to set the SQL query string in job
configuration XML file. Is it possible to parameterize them / send
dynamic values from the program?
E.g: Can i have the following?
In this way, the value for empid will be passed from the java program atCode:<beans:bean id="cursorReader" class="org.springframework.batch.item.database.JdbcCursorItemReader"> <beans:property name="dataSource" ref="dataSource" /> <beans:property name="rowMapper" ref="cursorReaderRowMapper" /> <beans:property name="sql" value="select * from emp where empid = ?"/> </beans:bean>
runtime.
If it is possible, please let me know the way to do it.
Thanks
--venkat


Reply With Quote
