Dev - seed data loading problem

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Dev - seed data loading problem

Hans Bakker
Currently (Rev: 7579) when only loading the seed data i get the following
error in file:
/home/ofbiz/ofbiz/applications/order/data/OrderTypeData.xml

Failure in store operation for entity [ReturnItemTypeMap]:
org.ofbiz.entity.GenericEntityException: Exception while updating the
following entity: [GenericEntity:ReturnItemTypeMap]
[lastUpdatedStamp,2006-05-13 20:15:29.256(java.sql.Timestamp)]
[lastUpdatedTxStamp,2006-05-13 20:15:28.73(java.sql.Timestamp)]
[returnHeaderTypeId,CUSTOMER_RETURN(java.lang.String)]
[returnItemMapKey,REPLACE_ADJUSTMENT(java.lang.String)]
[returnItemTypeId,RET_REPLACE_ADJ(java.lang.String)] (while updating:
[GenericEntity:ReturnItemTypeMap][lastUpdatedStamp,2006-05-13 20:15:29.256
(java.sql.Timestamp)][lastUpdatedTxStamp,2006-05-13 20:15:28.73
(java.sql.Timestamp)][returnHeaderTypeId,CUSTOMER_RETURN(java.lang.String)]
[returnItemMapKey,REPLACE_ADJUSTMENT(java.lang.String)]
[returnItemTypeId,RET_REPLACE_ADJ(java.lang.String)] (SQL Exception while
executing the following:UPDATE public.RETURN_ITEM_TYPE_MAP SET
RETURN_ITEM_TYPE_ID=?, LAST_UPDATED_TX_STAMP=?, LAST_UPDATED_STAMP=? WHERE
RETURN_ITEM_MAP_KEY=? AND RETURN_HEADER_TYPE_ID=? (ERROR: insert or update on
table "return_item_type_map" violates foreign key constraint
"return_item_map"))). Rolling back transaction.


--
Regards,
Hans Bakker
ANT Websystems Co.,Ltd (http://www.antwebsystems.com)

If you want to verify that this message really originates from
from the above person, download the public key from:
http://www.antwebsystems.com/hbakkerAntwebsystems.asc

 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev

attachment0 (196 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Dev - seed data loading problem

Ray Barlow
Hans,

I bet you are running on Postgres or something more strict than Derby.

See attached patch to the file that adds the missing data. Whoever
created the file should probably review it before it gets committed to
SVN to make sure the descriptions and parent type relations are correct,
but it will enable you to load the seed data for now.

Ray


Hans Bakker wrote:

>Currently (Rev: 7579) when only loading the seed data i get the following
>error in file:
>/home/ofbiz/ofbiz/applications/order/data/OrderTypeData.xml
>
>Failure in store operation for entity [ReturnItemTypeMap]:
>org.ofbiz.entity.GenericEntityException: Exception while updating the
>following entity: [GenericEntity:ReturnItemTypeMap]
>[lastUpdatedStamp,2006-05-13 20:15:29.256(java.sql.Timestamp)]
>[lastUpdatedTxStamp,2006-05-13 20:15:28.73(java.sql.Timestamp)]
>[returnHeaderTypeId,CUSTOMER_RETURN(java.lang.String)]
>[returnItemMapKey,REPLACE_ADJUSTMENT(java.lang.String)]
>[returnItemTypeId,RET_REPLACE_ADJ(java.lang.String)] (while updating:
>[GenericEntity:ReturnItemTypeMap][lastUpdatedStamp,2006-05-13 20:15:29.256
>(java.sql.Timestamp)][lastUpdatedTxStamp,2006-05-13 20:15:28.73
>(java.sql.Timestamp)][returnHeaderTypeId,CUSTOMER_RETURN(java.lang.String)]
>[returnItemMapKey,REPLACE_ADJUSTMENT(java.lang.String)]
>[returnItemTypeId,RET_REPLACE_ADJ(java.lang.String)] (SQL Exception while
>executing the following:UPDATE public.RETURN_ITEM_TYPE_MAP SET
>RETURN_ITEM_TYPE_ID=?, LAST_UPDATED_TX_STAMP=?, LAST_UPDATED_STAMP=? WHERE
>RETURN_ITEM_MAP_KEY=? AND RETURN_HEADER_TYPE_ID=? (ERROR: insert or update on
>table "return_item_type_map" violates foreign key constraint
>"return_item_map"))). Rolling back transaction.
>
>
>  
>
>------------------------------------------------------------------------
>
>
>_______________________________________________
>Dev mailing list
>[hidden email]
>http://lists.ofbiz.org/mailman/listinfo/dev
>

Index: OrderTypeData.xml
===================================================================
--- OrderTypeData.xml (revision 7150)
+++ OrderTypeData.xml (working copy)
@@ -194,6 +194,16 @@
     <ReturnItemType description="Return Finished/Digital Good Item" returnItemTypeId="RET_FDPROD_ITEM" parentTypeId="RET_PROD_ITEM"/>
     <ReturnItemType description="Return Product-Feature Item" returnItemTypeId="RET_PROD_FEATR_ITEM" parentTypeId="RET_PROD_ITEM"/>
     <ReturnItemType description="Return Service Product Item" returnItemTypeId="RET_SPROD_ITEM" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Promotional Adjustment" returnItemTypeId="RET_PROMOTION_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Replace Adjustment" returnItemTypeId="RET_REPLACE_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Discount Adjustment" returnItemTypeId="RET_DISCOUNT_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Fee Adjustment" returnItemTypeId="RET_FEE_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Misc Charge Adjustment" returnItemTypeId="RET_MISC_CHARGE_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Sales Tax Adjustment" returnItemTypeId="RET_SALES_TAX_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Shipping Adjustment" returnItemTypeId="RET_SHIPPING_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Surcharge Adjustment" returnItemTypeId="RET_SURCHARGE_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Add Feature Adjustment" returnItemTypeId="RET_ADD_FEATURE_ADJ" parentTypeId="RET_PROD_ITEM"/>
+    <ReturnItemType description="Return Warranty Adjustment" returnItemTypeId="RET_WARRANTY_ADJ" parentTypeId="RET_PROD_ITEM"/>
 
     <ReturnItemType description="Return Work-Effort Item" returnItemTypeId="RET_WE_ITEM" parentTypeId=""/>
     <ReturnItemType description="Return Time-Entry Item" returnItemTypeId="RET_TE_ITEM" parentTypeId=""/>

 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev
Reply | Threaded
Open this post in threaded view
|

Re: Dev - seed data loading problem

Hans Bakker
I checked both on derby and postGresql...both have the same problem....

On Sunday 14 May 2006 13:40, Ray wrote:

> Hans,
>
> I bet you are running on Postgres or something more strict than Derby.
>
> See attached patch to the file that adds the missing data. Whoever
> created the file should probably review it before it gets committed to
> SVN to make sure the descriptions and parent type relations are correct,
> but it will enable you to load the seed data for now.
>
> Ray
>
> Hans Bakker wrote:
> >Currently (Rev: 7579) when only loading the seed data i get the following
> >error in file:
> >/home/ofbiz/ofbiz/applications/order/data/OrderTypeData.xml
> >
> >Failure in store operation for entity [ReturnItemTypeMap]:
> >org.ofbiz.entity.GenericEntityException: Exception while updating the
> >following entity: [GenericEntity:ReturnItemTypeMap]
> >[lastUpdatedStamp,2006-05-13 20:15:29.256(java.sql.Timestamp)]
> >[lastUpdatedTxStamp,2006-05-13 20:15:28.73(java.sql.Timestamp)]
> >[returnHeaderTypeId,CUSTOMER_RETURN(java.lang.String)]
> >[returnItemMapKey,REPLACE_ADJUSTMENT(java.lang.String)]
> >[returnItemTypeId,RET_REPLACE_ADJ(java.lang.String)] (while updating:
> >[GenericEntity:ReturnItemTypeMap][lastUpdatedStamp,2006-05-13 20:15:29.256
> >(java.sql.Timestamp)][lastUpdatedTxStamp,2006-05-13 20:15:28.73
> >(java.sql.Timestamp)][returnHeaderTypeId,CUSTOMER_RETURN(java.lang.String)
> >] [returnItemMapKey,REPLACE_ADJUSTMENT(java.lang.String)]
> >[returnItemTypeId,RET_REPLACE_ADJ(java.lang.String)] (SQL Exception while
> >executing the following:UPDATE public.RETURN_ITEM_TYPE_MAP SET
> >RETURN_ITEM_TYPE_ID=?, LAST_UPDATED_TX_STAMP=?, LAST_UPDATED_STAMP=? WHERE
> >RETURN_ITEM_MAP_KEY=? AND RETURN_HEADER_TYPE_ID=? (ERROR: insert or update
> > on table "return_item_type_map" violates foreign key constraint
> >"return_item_map"))). Rolling back transaction.
> >
> >
> >
> >
> >------------------------------------------------------------------------
> >
> >
> >_______________________________________________
> >Dev mailing list
> >[hidden email]
> >http://lists.ofbiz.org/mailman/listinfo/dev
--
Regards,
Hans Bakker
ANT Websystems Co.,Ltd (http://www.antwebsystems.com)

If you want to verify that this message really originates from
from the above person, download the public key from:
http://www.antwebsystems.com/hbakkerAntwebsystems.asc

 
_______________________________________________
Dev mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/dev

attachment0 (196 bytes) Download Attachment