Doctrine DBAL
  1. Doctrine DBAL
  2. DBAL-257

OCI8Statement::fetchColumn() returns null instead of false

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.2.2
    • Fix Version/s: None
    • Component/s: Drivers
    • Security Level: All
    • Labels:
      None

      Description

      In
      public function fetchColumn($columnIndex = 0)
      {
      $row = oci_fetch_array($this->_sth, OCI_NUM | OCI_RETURN_NULLS | OCI_RETURN_LOBS);
      return $row[$columnIndex];
      }

      there is no control on oci_fetch_array_() returned value.
      When it returns false fetchColumn() returns null instead of false.

      Solution:
      public function fetchColumn($columnIndex = 0)
      {
      $row = oci_fetch_array($this->_sth, OCI_NUM | OCI_RETURN_NULLS | OCI_RETURN_LOBS);
      return isset($row[$columnIndex]) ? $row[$columnIndex] : false;
      }

        Activity

        lorenzo zoffoli created issue -
        Hide
        Benjamin Eberlei added a comment -

        Fixed

        Show
        Benjamin Eberlei added a comment - Fixed
        Benjamin Eberlei made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 2.2.3 [ 10210 ]
        Resolution Fixed [ 1 ]
        Benjamin Eberlei made changes -
        Workflow jira [ 13635 ] jira-feedback2 [ 17816 ]
        Benjamin Eberlei made changes -
        Workflow jira-feedback2 [ 17816 ] jira-feedback3 [ 20171 ]
        Guilherme Blanco made changes -
        Fix Version/s 2.2.3 [ 10210 ]

        This list may be incomplete, as errors occurred whilst retrieving source from linked applications:

        • Request to http://www.doctrine-project.org/fisheye/ failed: Error in remote call to 'FishEye 0 (http://www.doctrine-project.org/fisheye/)' (http://www.doctrine-project.org/fisheye) [AbstractRestCommand{path='/rest-service-fe/search-v1/crossRepositoryQuery', params={query=DBAL-257, expand=changesets[0:20].revisions[0:29],reviews}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)

          People

          • Assignee:
            Benjamin Eberlei
            Reporter:
            lorenzo zoffoli
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: