예제 #1
0
파일: Schema.php 프로젝트: df-arif/df-core
 public static function formatValue($value, $type)
 {
     $value = parent::formatValue($value, $type);
     if (' ' === $value) {
         // SQL Anywhere strangely returns empty string as a single space string
         return '';
     }
     return $value;
 }
예제 #2
0
파일: Schema.php 프로젝트: df-arif/df-core
 public static function formatValue($value, $type)
 {
     if ('int' === $type && '' === $value) {
         // Postgresql strangely returns "" for null integers
         return null;
     }
     return parent::formatValue($value, $type);
 }
예제 #3
0
 public static function formatValue($value, $type)
 {
     switch (strtolower(strval($type))) {
         case 'int':
         case 'integer':
             if ('' === $value) {
                 // Postgresql strangely returns "" for null integers
                 return null;
             }
     }
     return parent::formatValue($value, $type);
 }