When importing XML to the DB, if an attribute has an empty
value, the Entity Sax Reader skips the attribute and therefore does NOT update
the value in the DB. For Example: If the DB PRODUCT.PRODUCT_NAME contains a value of ‘My Product Name’. Using the following XML will not update the PRODUCT_NAME to
empty. <entity-engine-xml> <Product productId=”12345” productName=””/> </entity-engine-xml> Is there a property or setting that will allow the XML to
update the DB with an empty attribute value? Thank You Len Shein 516.742.7888 ext.225 732.333.4303 |
What your ofbiz version ?
If it's trunk, try : <entity-engine-xml> <create-replace> <Product productId=”12345” *productName=””*/> </create-replace> </entity-engine-xml> If it's 12.04, I can use a backport addon http://addons.neogia.org/addons-12.04/ofbiz-backport-loading-data-actions-tag/ to use this fonctionnality. Nicolas Le 28/06/2013 20:11, Len Shein a écrit : > > When importing XML to the DB, if an attribute has an empty value, the > Entity Sax Reader skips the attribute and therefore does NOT update > the value in the DB. > > For Example: > > If the DB PRODUCT.PRODUCT_NAME contains a value of ‘*My Product Name*’. > > Using the following XML will not update the PRODUCT_NAME to empty. > > <entity-engine-xml> > > <Product productId=”12345” *productName=””*/> > > </entity-engine-xml> > > Is there a property or setting that will allow the XML to update the > DB with an empty attribute value? > > Thank You > > Len Shein > > [hidden email] <mailto:[hidden email]> > > [hidden email] <mailto:[hidden email]> > > 516.742.7888 ext.225 > > 732.333.4303 > -- Nicolas MALIN Consultant Tél : 06.17.66.40.06 Site projet : http://www.neogia.org/ ------- Société LibrenBerry Tél : 02.48.02.56.12 Site : http://www.librenberry.net/ |
I am using Ofbiz version 10.04.
For now I will review the addon and see what I can use in this version. Thanks Len -----Original Message----- From: Nicolas Malin [mailto:[hidden email]] Sent: Friday, June 28, 2013 2:35 PM To: [hidden email] Subject: Re: XML Import to Datasource What your ofbiz version ? If it's trunk, try : <entity-engine-xml> <create-replace> <Product productId=12345 *productName=*/> </create-replace> </entity-engine-xml> If it's 12.04, I can use a backport addon http://addons.neogia.org/addons-12.04/ofbiz-backport-loading-data-actions-ta g/ to use this fonctionnality. Nicolas Le 28/06/2013 20:11, Len Shein a écrit : > > When importing XML to the DB, if an attribute has an empty value, the > Entity Sax Reader skips the attribute and therefore does NOT update > the value in the DB. > > For Example: > > If the DB PRODUCT.PRODUCT_NAME contains a value of *My Product Name*. > > Using the following XML will not update the PRODUCT_NAME to empty. > > <entity-engine-xml> > > <Product productId=12345 *productName=*/> > > </entity-engine-xml> > > Is there a property or setting that will allow the XML to update the > DB with an empty attribute value? > > Thank You > > Len Shein > > [hidden email] <mailto:[hidden email]> > > [hidden email] <mailto:[hidden email]> > > 516.742.7888 ext.225 > > 732.333.4303 > -- Nicolas MALIN Consultant Tél : 06.17.66.40.06 Site projet : http://www.neogia.org/ ------- Société LibrenBerry Tél : 02.48.02.56.12 Site : http://www.librenberry.net/ |
Free forum by Nabble | Edit this page |