I've changed it to the one you've described (which is similar to the ones
mention in the docs). And the read part still works fine. However, I think
this is really an issue of the paramerMap being applied incorrectly. Using the
? style, I have the following which refuses to insert but when i use inline
parameter maps instead of ?, everthing works fine. You mentioned that there is
another way of applying parameter maps (using @ShipmentId etc) which I somewhat
prefer. I can't find documentation on that anywhere. Can somebody point me in
the right direction.
Thanks for all your help.
In agony,
Zarar
<statement id="insertShipmentDimensions" parmaterMap="parameterDimensions">
INSERT INTO nlmi_dimensions
(ShipmentId,Pieces,Weight,Length,Width,Height,Stackable)
VALUES (?,?,?,?,?,?,?)
</statement>
<parameterMap id="parameterDimensions" class="pearl.nlmi.vo.Dimensions">
<parameter property="ShipmentId"/>
<parameter property="Pieces"/>
<parameter property="Weight"/>
<parameter property="Length"/>
<parameter property="Width"/>
<parameter property="Height"/>
<parameter property="Stackable" dbType="Varchar" type="bool"/>
</parameterMap>
-------Original Message-------
> From: David Marzo (Puzzlet) <[EMAIL PROTECTED]>
> Subject: RE: TypeHandler Problem using <parameterMap>
> Sent: 18 Aug '05 11:33
>
> I use custom TypeHandler with no problem, but i declare a type handler
> in
> SqlMap.config
>
> Like:
>
> <typeHandler type="System.Decimal" dbType="Decimal"
> callback="persistence.access.mapper.AccessDecimalTypeHandlerCallBack,Per
> sistence.Access"></typeHandler>
>
> But I belive thath set TypeHandler in Property works fine, set up a
> breakpoint in
>
> IBatisNet.DataMapper.MappedStatements. ApplyResultMap( ... ) in Line 277
>
> An see if the value of property.TypeHandler is correct.
>
> First try to replace the #ShipmentId#, # Pieces #, #Weight#, #Length#,
> ...
> in the insertShipmentDimensions for ?,?,?,etc .. or named parameters
> @ShipmentId, @Pieces, etc ..
> I think ## is interpreted as inline parameter ingnoring your
> parameterMap configuration ;-).
>
> Note: MS access no support milliseconds in DateTime but OleDB provider
> support it. That cause an error when you try to INSERT/UPDATE a DateTime
> with not milliseconds set to cero, I fix this with a TypeHandler ;-)
>
> Hope this help
>
>
>
>
-------Original Message-------