Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-745

Null CIVICRM_PROVINCE_LIMIT causes fatal error in CiviContribute Page

    Details

    • Type: Bug
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: 1.3
    • Fix Version/s: 1.4
    • Component/s: None
    • Labels:
      None

      Description

      If your CIVICRM_PROVINCE_LIMIT setting is '' (null) - and you try and load a CiviContribute page (contribute/transact?id=1&reset=1) - you get the following fatal SQL error due to empty value in IN () clause. Need to bypass that filter for this config case.

      ----------
      Sorry. A non-recoverable error has occurred.
      Database Error Code: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') ORDER BY name' at line 1, 1064
      [message] => DB Error: syntax error
      [mode] => 16
      [debug_info] => SELECT id, name FROM civicrm_state_province WHERE country_id IN () ORDER BY name [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') ORDER BY name' at line 1]

        Attachments

          Activity

            People

            • Assignee:
              kurund Kurund Jalmi
              Reporter:
              dgg David Greenberg
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: