Uploaded image for project: 'Contrib: Gradebook2'
  1. Contrib: Gradebook2
  2. GRBK-1076

Enhanced Search does not work on Oracle

    Details

      Description

      The new search functionality implemented in GRBK-485 works on MySql but not Oracle. MySQL queries are case-insensitive, but in Oracle, the search parameters must match the case of the values in the database table. This can be fixed in the HQL for the search criteria by converting both values to lower case (or upper case). Here's an example of the HQL for the search criteria that works in MySQL but not Oracle:

      builder.append("and user.").append(searchField).append(" like :searchCriteria ");

      This works in both if changed like this:

      builder.append("and lower(user.").append(searchField).append(") like lower(:searchCriteria) ");

        Gliffy Diagrams

          Issue Links

            Activity

            Hide
            jimeng Jim Eng added a comment -

            This could also be solved using the hibernate Restriction.ilike() method.

            Show
            jimeng Jim Eng added a comment - This could also be solved using the hibernate Restriction.ilike() method.
            Hide
            tamsler Thomas Amsler added a comment -

            Merged UMICH patch into:

            • trunk
            • branches/1.5.x-test

            Created https://source.sakaiproject.org/contrib//gradebook2/tags/1.5.1-b2/ tag containing this change.

            Show
            tamsler Thomas Amsler added a comment - Merged UMICH patch into: trunk branches/1.5.x-test Created https://source.sakaiproject.org/contrib//gradebook2/tags/1.5.1-b2/ tag containing this change.
            Hide
            ncwilkison@ucdavis.edu Nancy Wilkison added a comment -

            how do I test this one?

            Show
            ncwilkison@ucdavis.edu Nancy Wilkison added a comment - how do I test this one?
            Hide
            ccjon Jon Gorrono added a comment - - edited

            search for students using upper and lower case.... should end up with the same results regardless.

            Show
            ccjon Jon Gorrono added a comment - - edited search for students using upper and lower case.... should end up with the same results regardless.
            Hide
            ncwilkison@ucdavis.edu Nancy Wilkison added a comment -

            DEV
            SmartSite@UCDavis - 2.7.2-rc1 - Sakai 2.7.1 - Server "ucddev1"
            gradebook2 v1.6.0-a7

            TEST PROCESS -
            used Find to search for students using a variety of upper case only, lower case only and mixed case criteria.
            found the same students in all instances.

            QA RESULTS -
            pass

            if that's all I had to do

            Show
            ncwilkison@ucdavis.edu Nancy Wilkison added a comment - DEV SmartSite@UCDavis - 2.7.2-rc1 - Sakai 2.7.1 - Server "ucddev1" gradebook2 v1.6.0-a7 TEST PROCESS - used Find to search for students using a variety of upper case only, lower case only and mixed case criteria. found the same students in all instances. QA RESULTS - pass if that's all I had to do

              People

              • Assignee:
                Unassigned
                Reporter:
                bkirschn Beth Kirschner
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: