If I understand you correctly, you can do something like this: class Foo extends SqlMapClientDaoSupport {
public Foo(DataSource ds) { super.setDataSource(ds); ClassPathResource cpr = new ClassPathResource("com/foo/dao/ibatisSQLMapsConfig.xml"); /* spring class*/ SqlMapClient smc = SqlMapClientBuilder.buildSqlMapClient(new FileReader(cpr.getFile())); super.setSqlMapClient(smc); > Hello i am using ibatis but i must to load the datasource form one class > file. > is this posible? > > i have one classfile that returns one datasource. is posible to use this > file to load the conection and datasource to the data base for ibatis? > thanks