mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
postgres should use INT8 only for very large integers, see bug1590
This commit is contained in:
parent
097f75d1a0
commit
09d4c9a984
1 changed files with 3 additions and 3 deletions
|
@ -141,13 +141,13 @@ function table_column($table, $oldfield, $field, $type="integer", $size="10",
|
|||
|
||||
switch (strtolower($type)) {
|
||||
case "integer":
|
||||
if ($size <= 2) {
|
||||
if ($size <= 4) {
|
||||
$type = "INT2";
|
||||
}
|
||||
if ($size <= 4) {
|
||||
if ($size <= 10) {
|
||||
$type = "INT";
|
||||
}
|
||||
if ($size > 4) {
|
||||
if ($size > 10) {
|
||||
$type = "INT8";
|
||||
}
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue