[
https://issues.apache.org/jira/browse/OFBIZ-2192?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jacques Le Roux closed OFBIZ-2192.
----------------------------------
Resolution: Fixed
Fix Version/s: Release Branch 4.0
Assignee: Jacques Le Roux
Thanks Jan,
Yes, this is a known bug. Hopefully we have fixed all occurences in trunk some
months ago. The recommended way of fixing it is to put something like
<set field="productsSoldThruTimestamp"
from-field="parameters.productsSoldThruTimestamp" type="Timestamp"/>
in FacilityScreens.xml#ViewFacilityInventoryByProduct
Done in revision 744964.
> GenericDataSourceException in ViewFacilityInventoryByProduct.bsh on pgSQL 8.3
> -----------------------------------------------------------------------------
>
> Key: OFBIZ-2192
> URL: https://issues.apache.org/jira/browse/OFBIZ-2192
> Project: OFBiz
> Issue Type: Bug
> Components: product
> Affects Versions: Release Branch 4.0
> Environment: SQL: PostgreSQL 8.3.5
> JDBC Driver: postgresql-8.3-603.jdbc4.jar
> Reporter: Jan Valkovic
> Assignee: Jacques Le Roux
> Priority: Minor
> Fix For: Release Branch 4.0
>
> Original Estimate: 0.08h
> Remaining Estimate: 0.08h
>
> Script:
> [OFBIZ_HOME]/product/webapp/facility/WEB-INF/actions/facility/ViewFacilityInventoryByProduct.bsh
> throws an exception:
> Target exception: org.ofbiz.entity.GenericDataSourceException: SQL Exception
> while executing the following:SELECT DISTINCT PROD.INTERNAL_NAME,
> PROD.IS_VIRTUAL, PROD.SALES_DISCONTINUATION_DATE, PROD.PRODUCT_TYPE_ID,
> PRFA.PRODUCT_ID, PRFA.FACILITY_ID, PRFA.MINIMUM_STOCK, PRFA.REORDER_QUANTITY,
> PRFA.DAYS_TO_SHIP FROM public.PRODUCT PROD INNER JOIN public.PRODUCT_FACILITY
> PRFA ON PROD.PRODUCT_ID = PRFA.PRODUCT_ID WHERE ((PRFA.FACILITY_ID = ? AND
> PROD.PRODUCT_TYPE_ID = ?) AND (PROD.IS_VIRTUAL IS NULL OR PROD.IS_VIRTUAL <>
> ?) AND (PROD.SALES_DISCONTINUATION_DATE IS NULL OR
> PROD.SALES_DISCONTINUATION_DATE > ?)) ORDER BY PRFA.PRODUCT_ID ASC (ERROR:
> operator does not exist: timestamp with time zone > character varying)
> I fixed this error by add explicit conversion to Timestamp in line 112:
> new EntityExpr("salesDiscontinuationDate", EntityOperator.GREATER_THAN,
> Timestamp.valueOf(productsSoldThruTimestamp)))
> I tested this only on Derby and pgSQL.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.