You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Adam Heath (JIRA)" <ji...@apache.org> on 2008/09/09 02:59:44 UTC

[jira] Created: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

delegator.removeByAnd(entityName) fails with sql syntax error
-------------------------------------------------------------

                 Key: OFBIZ-1952
                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
             Project: OFBiz
          Issue Type: Bug
          Components: framework
    Affects Versions: SVN trunk
            Reporter: Adam Heath
            Priority: Minor


delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:

sql += "WHERE" + condition.makeWhereString(...)

fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

Posted by "David E. Jones (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12657109#action_12657109 ] 

David E. Jones commented on OFBIZ-1952:
---------------------------------------

Looks good to me.

> delegator.removeByAnd(entityName) fails with sql syntax error
> -------------------------------------------------------------
>
>                 Key: OFBIZ-1952
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Adam Heath
>            Assignee: Christian Geisert
>            Priority: Minor
>         Attachments: GenericDAO.patch
>
>
> delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:
> sql += "WHERE" + condition.makeWhereString(...)
> fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

Posted by "Bruno Busco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco closed OFBIZ-1952.
------------------------------


Changed from "Resolved" to "Closed" since we do not use the "Resolved" issue status

> delegator.removeByAnd(entityName) fails with sql syntax error
> -------------------------------------------------------------
>
>                 Key: OFBIZ-1952
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Adam Heath
>            Assignee: Christian Geisert
>            Priority: Minor
>         Attachments: GenericDAO.patch
>
>
> delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:
> sql += "WHERE" + condition.makeWhereString(...)
> fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

Posted by "Christian Geisert (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Geisert reassigned OFBIZ-1952:
----------------------------------------

    Assignee: Christian Geisert

> delegator.removeByAnd(entityName) fails with sql syntax error
> -------------------------------------------------------------
>
>                 Key: OFBIZ-1952
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Adam Heath
>            Assignee: Christian Geisert
>            Priority: Minor
>         Attachments: GenericDAO.patch
>
>
> delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:
> sql += "WHERE" + condition.makeWhereString(...)
> fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

Posted by "Marco Ruocco (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marco Ruocco updated OFBIZ-1952:
--------------------------------

    Attachment: GenericDAO.patch

Hi,

in this attachment I propose my solution to that issue. 
I have worked on OFBiz revision 724649 on MS Windows XP System

> delegator.removeByAnd(entityName) fails with sql syntax error
> -------------------------------------------------------------
>
>                 Key: OFBIZ-1952
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Adam Heath
>            Priority: Minor
>         Attachments: GenericDAO.patch
>
>
> delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:
> sql += "WHERE" + condition.makeWhereString(...)
> fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

Posted by "Christian Geisert (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OFBIZ-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12657020#action_12657020 ] 

Christian Geisert commented on OFBIZ-1952:
------------------------------------------

I stumbled over this bug (and someone else too) in a project and we all came to the solution ;-)
It's really time to fix this...

> delegator.removeByAnd(entityName) fails with sql syntax error
> -------------------------------------------------------------
>
>                 Key: OFBIZ-1952
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Adam Heath
>            Assignee: Christian Geisert
>            Priority: Minor
>         Attachments: GenericDAO.patch
>
>
> delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:
> sql += "WHERE" + condition.makeWhereString(...)
> fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (OFBIZ-1952) delegator.removeByAnd(entityName) fails with sql syntax error

Posted by "Christian Geisert (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OFBIZ-1952?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christian Geisert resolved OFBIZ-1952.
--------------------------------------

    Resolution: Fixed

Patch committed, thanks for your contribution!

> delegator.removeByAnd(entityName) fails with sql syntax error
> -------------------------------------------------------------
>
>                 Key: OFBIZ-1952
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1952
>             Project: OFBiz
>          Issue Type: Bug
>          Components: framework
>    Affects Versions: SVN trunk
>            Reporter: Adam Heath
>            Assignee: Christian Geisert
>            Priority: Minor
>         Attachments: GenericDAO.patch
>
>
> delegator.removeByAnd(entityName) calls delegator.removeByAnd(entityName, (Map) null).  This eventually calls GenericDAO.deleteByCondition, with the condition being an EntityFieldMap with an emptyMap.  In this case, the EntityCondition.makeWhereString returns an empty string, so doing:
> sql += "WHERE" + condition.makeWhereString(...)
> fails.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.