You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Wai (JIRA)" <ji...@apache.org> on 2015/05/30 18:50:17 UTC

[jira] [Created] (OFBIZ-6434) In ofbizsetup, create product category causes exception

Wai created OFBIZ-6434:
--------------------------

             Summary: In ofbizsetup, create product category causes exception
                 Key: OFBIZ-6434
                 URL: https://issues.apache.org/jira/browse/OFBIZ-6434
             Project: OFBiz
          Issue Type: Bug
          Components: commonext/setup
    Affects Versions: Trunk
            Reporter: Wai


in ofbizsetup. create 1st productCategory gives exception.
Seems that ofbiz tries to auto create a promotions category but the resulting productCategoryId is too long for for the database field defined as a varchar(20).
My database is currently configured to use utf8.

...console output...
INSERT INTO public.PRODUCT_CATEGORY (PRODUCT_CATEGORY_ID, PRODUCT_CATEGORY_TYPE_ID, PRIMARY_PARENT_CATEGORY_ID, CATEGORY_NAME, DESCRIPTION, LONG_DESCRIPTION, CATEGORY_IMAGE_URL, LINK_ONE_IMAGE_URL, LINK_TWO_IMAGE_URL, DETAIL_SCREEN, SHOW_IN_SELECT, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP) VALUES ('MYCOCLG1_ID_PROMOTIONS', 'CATALOG_CATEGORY', NULL, 'MYCOCLG1_ID Promotions', NULL, NULL, NULL, NULL, NULL, 'component://ecommerce/widget/CatalogScreens.xml#categorydetailmatrix', NULL, '2015-05-29 13:03:32.740000 -04:00:00', '2015-05-29 13:03:32.587000 -04:00:00', '2015-05-29 13:03:32.740000 -04:00:00', '2015-05-29 13:03:32.587000 -04:00:00')
2015-05-29 13:03:32,743 |ttp-bio-8443-exec-10 |GenericDelegator              |E| Failure in create operation for entity [ProductCategory]: org.ofbiz.entity.GenericEntityException: Error while inserting: [GenericEntity:ProductCategory][categoryName,MYCOCLG1_ID Promotions(java.lang.String)][createdStamp,2015-05-29 13:03:32.74(java.sql.Timestamp)][createdTxStamp,2015-05-29 13:03:32.587(java.sql.Timestamp)][detailScreen,component://ecommerce/widget/CatalogScreens.xml#categorydetailmatrix(java.lang.String)][lastUpdatedStamp,2015-05-29 13:03:32.74(java.sql.Timestamp)][lastUpdatedTxStamp,2015-05-29 13:03:32.587(java.sql.Timestamp)][productCategoryId,MYCOCLG1_ID_PROMOTIONS(java.lang.String)][productCategoryTypeId,CATALOG_CATEGORY(java.lang.String)] (SQL Exception while executing the following:INSERT INTO public.PRODUCT_CATEGORY (PRODUCT_CATEGORY_ID, PRODUCT_CATEGORY_TYPE_ID, PRIMARY_PARENT_CATEGORY_ID, CATEGORY_NAME, DESCRIPTION, LONG_DESCRIPTION, CATEGORY_IMAGE_URL, LINK_ONE_IMAGE_URL, LINK_TWO_IMAGE_URL, DETAIL_SCREEN, SHOW_IN_SELECT, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) (ERROR: value too long for type character varying(20)))



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)