]> git.mxchange.org Git - core.git/commitdiff
If no valid entry (e.g. failed query) is counted, this does now return -1
authorRoland Häder <roland@mxchange.org>
Fri, 28 May 2010 02:30:41 +0000 (02:30 +0000)
committerRoland Häder <roland@mxchange.org>
Fri, 28 May 2010 02:30:41 +0000 (02:30 +0000)
inc/classes/main/database/class_BaseDatabaseWrapper.php

index e86b0c65de99340025b03d4edc6da29daabc1d0d..494d994b43f685df2fb3514a61b5ab9ad3a2e2ed 100644 (file)
@@ -30,7 +30,7 @@ class BaseDatabaseWrapper extends BaseFrameworkSystem {
        /**
         * Current table name to use
         */
-       private $tableName = "unknown";
+       private $tableName = 'unknown';
 
        /**
         * Protected constructor
@@ -84,7 +84,7 @@ class BaseDatabaseWrapper extends BaseFrameworkSystem {
                        } else {
                                // This invalid result must be wrapped
                                $result = array(
-                                       'status'                => "invalid",
+                                       'status'                => 'invalid',
                                        'exception'             => $this->getDatabaseInstance()->getLastException()
                                );
                        }
@@ -104,7 +104,7 @@ class BaseDatabaseWrapper extends BaseFrameworkSystem {
         * @return      $numRows                        Numbers of rows of database entries
         */
        public function doSelectCountByCriteria (Criteria $criteriaInstance) {
-               // Total numbers is zero by default
+               // Total numbers is -1 so we can distinglish between failed and valid queries
                $numRows = 0;
 
                // Get the result from above method