Thanks a lot Tom!
"Nguyen, Tom" <[EMAIL PROTECTED]> a écrit : v\:*
{behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:*
{behavior:url(#default#VML);} .shape {behavior:url(#default#VML);}
Well, if you have a modification date/author column then its easier
UPDATE PRODUIT
SET LastModifedDate = getdate()
<dynamic>
<isGreaterEqual property=IdCategory compareValue=0>
, idCat = #IdCategory#
</isGreaterEqual>
</dynamic>
WHERE idProduit = #IdProduit#
Regards,
Tom Nguyen
---------------------------------
From: Tite Etoundi [mailto:[EMAIL PROTECTED]
Sent: Wednesday, November 29, 2006 4:09 PM
To: [email protected]
Subject: efficient management of comma in dynamic statement
Hi,
Plz do anybody could help me how can I manage comma in statement as the
follow:
<update id="UpdateProduct" parameterClass="ProduitVOType" >
UPDATE PRODUIT SET
<dynamic>
<isGreaterEqual property="IdCategory" compareValue="0">
idCat = #IdCategory#
</isGreaterEqual>
<isNotNull property="CaractTechniques" prepend=",">
caracteristiquesTech = #CaractTechniques#
</isNotNull>
<isNotEmpty property="DescriptionDetaillee" prepend=",">
descDetaillee = #DescriptionDetaillee#
</isNotEmpty>
<isNotEmpty property="ImageBasePath" prepend=",">
imageBasePath = #ImageBasePath#
</isNotEmpty>
<isNotEmpty property="NomProduit" prepend=",">
name = #NomProduit#
</isNotEmpty>
<isGreaterEqual property="QteEnStock" compareValue="0"
prepend=",">
qteEnStock = #QteEnStock#
</isGreaterEqual>
</dynamic>
WHERE idProduit = #IdProduit#
</update>
For example when QteEnStock = -1 or IdCategory = -1, I get the following
exception {"Line 1: Incorrect syntax near ','."}
There could be a lot of cases as this one in this statement.
Could somebody help me?
Thanks.
------------------------------------------
Etoundi Aboa Tite E.
Ingénieur Polytechnicien
Maître ès Science Informatique
Concepteur de Solutions Mobiles
Développeur d'applications SimToolKit
Tel: 935 60 14
------------------------------------------
---------------------------------
Yahoo! Mail réinvente le mail ! Découvrez le nouveau Yahoo! Mail et son
interface révolutionnaire.
---------------------------------
This e-mail message and any files transmitted herewith, are intended solely
for the use of the individual(s) addressed and may contain confidential,
proprietary or privileged information. If you are not the addressee indicated
in this message (or responsible for delivery of this message to such person)
you may not review, use, disclose or distribute this message or any files
transmitted herewith. If you receive this message in error, please contact the
sender by reply e-mail and delete this message and all copies of it from your
system.
---------------------------------
------------------------------------------
Etoundi Aboa Tite E.
Ingénieur Polytechnicien
Maître ès Science Informatique
Concepteur de Solutions Mobiles
Développeur d'applications SimToolKit
Tel: 935 60 14
------------------------------------------
---------------------------------
Découvrez une nouvelle façon d'obtenir des réponses à toutes vos questions !
Profitez des connaissances, des opinions et des expériences des internautes sur
Yahoo! Questions/Réponses.