ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brandon Goodin <brandon.goo...@gmail.com>
Subject Re: Dynamically add sqlMaps to Config.xml
Date Sun, 29 May 2005 14:41:11 GMT
I am a bit confused as to what you are asking. Do you just want to add
an sql map xml file dynamically?

Brandon

On 5/27/05, Steffen Legler <s.legler@tu-bs.de> wrote:
> Hi.
> 
> We need to add dynamically sqlMaps to our SqlMapClient.
> Please can you implement something like this example in further releases?
> 
> Example:
>  sqlMapClient = SqlMapClientBuilder.buildSqlMapClient(configReader, props);
>  sqlMapClient.addResource(xyz.xml)
> 
> Dynamically build SQL-Statements include a lot of spaces when using conditional
> Elements like <isEqual>. The Database doesn't care, but for logging it would be
> nice to have a well written sql-statement.
> 
> <update id="update" parameterClass="class">
>  update table set
>  <isEqual property="unit_type_selectionId" compareValue="2">
>   column=#column#
>  </isEqual>
>  <isEqual property="unit_type_selectionId" compareValue="2">
>   column1=#column#
>  </isEqual>
> where id=#id#
> </update>
> 
> Sql-Statement:
>          update table set              column=#column#        where id=#id#
> 
> Hope its possible to implement this two functions in future releases.
> 
> Thanks,
> Steffen
>

Mime
View raw message