Hi All,

I need to connect to two different datasources so I declared below way in applicationContext.xml file

Code:
<bean id="dataSource" class="org.springframework.jndi.JndiObjectFactoryBean">
    <property name="jndiName" value="eDB" /> 
	</bean>
	
	<bean id="sybaseSource" class="org.springframework.jndi.JndiObjectFactoryBean">
		<property name="jndiName" value="cDB" />
	</bean>

	<bean id="jdbcTemplate" class="org.springframework.jdbc.core.JdbcTemplate">
		<property name="dataSource" ref="dataSource" />
	</bean>
	
	

	<bean id="sybaseTemplate" class="org.springframework.jdbc.core.JdbcTemplate">
		<property name="sybaseSource" ref="sybaseSource" />
	</bean>
When I try to deploy application, it is throwing below error

Code:
org.springframework.beans.InvalidPropertyException: Invalid property 'sybaseSour
ce' of bean class [org.springframework.jdbc.core.JdbcTemplate]: No property 'sybaseSource' found
        at org.springframework.beans.BeanWrapperImpl.convertForProperty(BeanWrap
perImpl.java:382)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.convertForProperty(AbstractAutowireCapableBeanFactory.java:1253)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1214)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.populateBean(AbstractAutowireCapableBeanFactory.java:978)
        at org.springframework.beans.factory.support.AbstractAutowireCapableBean
Factory.doCreateBean(AbstractAutowireCapableBeanFactory.java:462)
        Truncated. see log file for complete stacktrace
I don't understand why 'jdbcTemplate' is referring 'sybaseSource'?? can anyone please suggest me how to resolve this issue.

Thanks in advance.

Regards,
Sharath.