You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ofbiz.apache.org by "Jacques Le Roux (JIRA)" <ji...@apache.org> on 2018/05/01 10:15:00 UTC

[jira] [Updated] (OFBIZ-248) Exception on checkout with apostrophe in address

     [ https://issues.apache.org/jira/browse/OFBIZ-248?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jacques Le Roux updated OFBIZ-248:
----------------------------------
    Description: 
Copy of an old issue from Ray Barlow:

Create an order that contains an apostrophe in address line 1 i.e. "Gardener's Cottage"

The exception below is thrown during the order creation stage of checkout, the order is created and no error is visible to the customer, but blacklist check is failing.

You can see from this extract of the exception the cause of the problem:
 WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COTTAGE')

{code}
Exception:
 179768[ ServiceEcaRule.java:122:INFO ] Running Service ECA Service: resetGrandTot
 al, triggered by rule on Service: storeOrder
 179808[ RequestHandler.java:297:INFO ] [RequestHandler.doRequest]: Response is a
 chained request.
 179808[ RequestHandler.java:116:INFO ] [RequestHandler]: Chain in place: requestU
 ri=checkBlacklist nextView=null
 179818[ RequestHandler.java:199:INFO ] [Processing Request]: checkBlacklist
 179838[ CheckOutHelper.java:955:ERROR]
 ---- exception report ----------------------------------------------------------
 Problems with OrderBlacklist lookup.
 Exception: org.ofbiz.entity.GenericDataSourceException
 Message: SQL Exception while executing the following:SELECT BLACKLIST_STRING, ORDER_B
 LACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_T
 X_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COT
 TAGE') AND ORDER_BLACKLIST_TYPE_ID = ?)) (Unexpected token in statement [SELECT BLACK
 LIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREA
 TED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('blacklistString') = U
 PPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TYPE_ID = ?))])
 ---- stack trace ---------------------------------------------------------------
 org.ofbiz.entity.GenericDataSourceException: SQL Exception while executing the follow
 ing:SELECT BLACKLIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATE
 D_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('black
 listString') = UPPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TYPE_ID = ?)) (Unexpec
 ted token in statement [SELECT BLACKLIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATE
 D_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST
 WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TY
 PE_ID = ?))])
 org.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:386)
 org.ofbiz.entity.datasource.GenericDAO.selectListIteratorByCondition(GenericDAO.java:
 747)
 org.ofbiz.entity.datasource.GenericDAO.selectByCondition(GenericDAO.java:618)
 org.ofbiz.entity.datasource.GenericHelperDAO.findByCondition(GenericHelperDAO.java:16
 9)
 org.ofbiz.entity.GenericDelegator.findByCondition(GenericDelegator.java:1016)
 org.ofbiz.entity.GenericDelegator.findByOr(GenericDelegator.java:967)
 org.ofbiz.order.shoppingcart.CheckOutHelper.checkOrderBlacklist(CheckOutHelper.java:9
 53)
 org.ofbiz.order.shoppingcart.CheckOutEvents.checkOrderBlacklist(CheckOutEvents.java:4
 88)
 sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
{code}

 

  was:
Copy of an old issue from Ray Barlow:

 Create an order that contains an apostrophe in address line 1 i.e. "Gardener's Cottage"

The exception below is thrown during the order creation stage of checkout, the order is created and no error is visible to the customer, but blacklist check is failing.

You can see from this extract of the exception the cause of the problem:
WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COTTAGE')

Exception:
179768[ ServiceEcaRule.java:122:INFO ] Running Service ECA Service: resetGrandTot
al, triggered by rule on Service: storeOrder
179808[ RequestHandler.java:297:INFO ] [RequestHandler.doRequest]: Response is a
chained request.
179808[ RequestHandler.java:116:INFO ] [RequestHandler]: Chain in place: requestU
ri=checkBlacklist nextView=null
179818[ RequestHandler.java:199:INFO ] [Processing Request]: checkBlacklist
179838[ CheckOutHelper.java:955:ERROR]
---- exception report ----------------------------------------------------------
Problems with OrderBlacklist lookup.
Exception: org.ofbiz.entity.GenericDataSourceException
Message: SQL Exception while executing the following:SELECT BLACKLIST_STRING, ORDER_B
LACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_T
X_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COT
TAGE') AND ORDER_BLACKLIST_TYPE_ID = ?)) (Unexpected token in statement [SELECT BLACK
LIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREA
TED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('blacklistString') = U
PPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TYPE_ID = ?))])
---- stack trace ---------------------------------------------------------------
org.ofbiz.entity.GenericDataSourceException: SQL Exception while executing the follow
ing:SELECT BLACKLIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATE
D_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('black
listString') = UPPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TYPE_ID = ?)) (Unexpec
ted token in statement [SELECT BLACKLIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATE
D_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST
WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TY
PE_ID = ?))])
org.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:386)
org.ofbiz.entity.datasource.GenericDAO.selectListIteratorByCondition(GenericDAO.java:
747)
org.ofbiz.entity.datasource.GenericDAO.selectByCondition(GenericDAO.java:618)
org.ofbiz.entity.datasource.GenericHelperDAO.findByCondition(GenericHelperDAO.java:16
9)
org.ofbiz.entity.GenericDelegator.findByCondition(GenericDelegator.java:1016)
org.ofbiz.entity.GenericDelegator.findByOr(GenericDelegator.java:967)
org.ofbiz.order.shoppingcart.CheckOutHelper.checkOrderBlacklist(CheckOutHelper.java:9
53)
org.ofbiz.order.shoppingcart.CheckOutEvents.checkOrderBlacklist(CheckOutEvents.java:4
88)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

 All  	 Comments  	 Work Log  	 Change History  	  	  Sort Order: [navigator.ascending.order]
Comment by Guy Gershoni [05/Aug/05 11:28 AM]
[ Permlink ]
Please note that the attached diff files are based on svn release 5458.



> Exception on checkout with apostrophe in address
> ------------------------------------------------
>
>                 Key: OFBIZ-248
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-248
>             Project: OFBiz
>          Issue Type: Bug
>          Components: order
>            Reporter: Jacopo Cappellato
>            Assignee: Jacques Le Roux
>            Priority: Minor
>             Fix For: Trunk
>
>         Attachments: checkOrderBlacklist.patch, patch.patch
>
>
> Copy of an old issue from Ray Barlow:
> Create an order that contains an apostrophe in address line 1 i.e. "Gardener's Cottage"
> The exception below is thrown during the order creation stage of checkout, the order is created and no error is visible to the customer, but blacklist check is failing.
> You can see from this extract of the exception the cause of the problem:
>  WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COTTAGE')
> {code}
> Exception:
>  179768[ ServiceEcaRule.java:122:INFO ] Running Service ECA Service: resetGrandTot
>  al, triggered by rule on Service: storeOrder
>  179808[ RequestHandler.java:297:INFO ] [RequestHandler.doRequest]: Response is a
>  chained request.
>  179808[ RequestHandler.java:116:INFO ] [RequestHandler]: Chain in place: requestU
>  ri=checkBlacklist nextView=null
>  179818[ RequestHandler.java:199:INFO ] [Processing Request]: checkBlacklist
>  179838[ CheckOutHelper.java:955:ERROR]
>  ---- exception report ----------------------------------------------------------
>  Problems with OrderBlacklist lookup.
>  Exception: org.ofbiz.entity.GenericDataSourceException
>  Message: SQL Exception while executing the following:SELECT BLACKLIST_STRING, ORDER_B
>  LACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_T
>  X_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COT
>  TAGE') AND ORDER_BLACKLIST_TYPE_ID = ?)) (Unexpected token in statement [SELECT BLACK
>  LIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATED_TX_STAMP, CREA
>  TED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('blacklistString') = U
>  PPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TYPE_ID = ?))])
>  ---- stack trace ---------------------------------------------------------------
>  org.ofbiz.entity.GenericDataSourceException: SQL Exception while executing the follow
>  ing:SELECT BLACKLIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATED_STAMP, LAST_UPDATE
>  D_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST WHERE ((UPPER('black
>  listString') = UPPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TYPE_ID = ?)) (Unexpec
>  ted token in statement [SELECT BLACKLIST_STRING, ORDER_BLACKLIST_TYPE_ID, LAST_UPDATE
>  D_STAMP, LAST_UPDATED_TX_STAMP, CREATED_STAMP, CREATED_TX_STAMP FROM ORDER_BLACKLIST
>  WHERE ((UPPER('blacklistString') = UPPER('GARDENER'S COTTAGE') AND ORDER_BLACKLIST_TY
>  PE_ID = ?))])
>  org.ofbiz.entity.jdbc.SQLProcessor.prepareStatement(SQLProcessor.java:386)
>  org.ofbiz.entity.datasource.GenericDAO.selectListIteratorByCondition(GenericDAO.java:
>  747)
>  org.ofbiz.entity.datasource.GenericDAO.selectByCondition(GenericDAO.java:618)
>  org.ofbiz.entity.datasource.GenericHelperDAO.findByCondition(GenericHelperDAO.java:16
>  9)
>  org.ofbiz.entity.GenericDelegator.findByCondition(GenericDelegator.java:1016)
>  org.ofbiz.entity.GenericDelegator.findByOr(GenericDelegator.java:967)
>  org.ofbiz.order.shoppingcart.CheckOutHelper.checkOrderBlacklist(CheckOutHelper.java:9
>  53)
>  org.ofbiz.order.shoppingcart.CheckOutEvents.checkOrderBlacklist(CheckOutEvents.java:4
>  88)
>  sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> {code}
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)