Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-1729

Searching entities with non numeric chars in numeric field generates an error

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • Trunk
    • Release Branch 4.0, Trunk
    • framework
    • None
    • Win XP - OFBIZ SVN Trunk 642807

    Description

      Use WebTools->Entity Data Maintenance to find an entity.
      If a non numeric char is used in a numeric entity filed the following error is generated:

      org.ofbiz.widget.screen.ScreenRenderException: Error rendering screen component://webtools/widget/EntityScreens.xml#FindGeneric: org.ofbiz.base.util.GeneralException: Error running BSH script at location [component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh] (Error running BSH script at [component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh], line [76]: Sourced file: component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh : Method Invocation findByEntity.setString : at Line: 76 : in file: component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh : findByEntity .setString ( field .getName ( ) , fval )

      Target exception: java.lang.NumberFormatException: For input string: "w"
      (Sourced file: component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh : Method Invocation findByEntity.setString)) (Error running BSH script at location [component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh] (Error running BSH script at [component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh], line [76]: Sourced file: component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh : Method Invocation findByEntity.setString : at Line: 76 : in file: component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh : findByEntity .setString ( field .getName ( ) , fval )

      Target exception: java.lang.NumberFormatException: For input string: "w"
      (Sourced file: component://webtools/webapp/webtools/WEB-INF/actions/entity/FindGeneric.bsh : Method Invocation findByEntity.setString)))

      Attachments

        1. findGeneric.patch
          0.9 kB
          pranaypa
        2. findGeneric.patch
          1 kB
          pranaypa

        Activity

          People

            jleroux Jacques Le Roux
            bruno.busco Bruno Busco
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: