Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

added schema support for mysql bigints

  • Loading branch information...
commit 15555a73099e9e32d3e518d0588932863e41832c 1 parent 6a95b57
@tmacwill tmacwill authored markstory committed
Showing with 4 additions and 0 deletions.
  1. +4 −0 lib/Cake/Model/Datasource/Database/Mysql.php
View
4 lib/Cake/Model/Datasource/Database/Mysql.php
@@ -108,6 +108,7 @@ class Mysql extends DboSource {
'primary_key' => array('name' => 'NOT NULL AUTO_INCREMENT'),
'string' => array('name' => 'varchar', 'limit' => '255'),
'text' => array('name' => 'text'),
+ 'biginteger' => array('name' => 'bigint', 'limit' => '20'),
'integer' => array('name' => 'int', 'limit' => '11', 'formatter' => 'intval'),
'float' => array('name' => 'float', 'formatter' => 'floatval'),
'datetime' => array('name' => 'datetime', 'format' => 'Y-m-d H:i:s', 'formatter' => 'date'),
@@ -646,6 +647,9 @@ public function column($real) {
if (($col === 'tinyint' && $limit == 1) || $col === 'boolean') {
return 'boolean';
}
+ if (strpos($col, 'bigint') !== false || $col === 'bigint') {
+ return 'biginteger';
+ }
if (strpos($col, 'int') !== false) {
return 'integer';
}
Please sign in to comment.
Something went wrong with that request. Please try again.