aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/db/tools
diff options
context:
space:
mode:
authorTristan Darricau <tristan.darricau@sensiolabs.com>2016-01-18 23:29:41 +0100
committerTristan Darricau <tristan.darricau@sensiolabs.com>2016-01-18 23:29:41 +0100
commit39c9baa574646e807ec1768907c674791e922f27 (patch)
treeec307d05b384bba6538e0eb8762230b995c170a7 /phpBB/phpbb/db/tools
parentbcc5eac7ddc7dd61cab389ff31788571e92cede3 (diff)
parenta94c20faa24cd450d697efa65be837075ec3cceb (diff)
downloadforums-39c9baa574646e807ec1768907c674791e922f27.tar
forums-39c9baa574646e807ec1768907c674791e922f27.tar.gz
forums-39c9baa574646e807ec1768907c674791e922f27.tar.bz2
forums-39c9baa574646e807ec1768907c674791e922f27.tar.xz
forums-39c9baa574646e807ec1768907c674791e922f27.zip
Merge pull request #4121 from marc1706/ticket/11875
[ticket/11875] Use 4-byte integer instead of 3-byte integer for ID columns * marc1706/ticket/11875: [ticket/11875] Add back new line [ticket/11875] Change more columns to use UINT and add missings ones [ticket/11875] Add migration file [ticket/11875] Recreate schemas for install [ticket/11875] Create new map for UNSIGNED 4-byte integer [ticket/11875] Upgrade default data type from MEDIUMINT to INT
Diffstat (limited to 'phpBB/phpbb/db/tools')
-rw-r--r--phpBB/phpbb/db/tools/mssql.php2
-rw-r--r--phpBB/phpbb/db/tools/postgres.php1
-rw-r--r--phpBB/phpbb/db/tools/tools.php15
3 files changed, 13 insertions, 5 deletions
diff --git a/phpBB/phpbb/db/tools/mssql.php b/phpBB/phpbb/db/tools/mssql.php
index 6e58171040..a90a85bbb2 100644
--- a/phpBB/phpbb/db/tools/mssql.php
+++ b/phpBB/phpbb/db/tools/mssql.php
@@ -36,6 +36,7 @@ class mssql extends tools
'mssql' => array(
'INT:' => '[int]',
'BINT' => '[float]',
+ 'ULINT' => '[int]',
'UINT' => '[int]',
'UINT:' => '[int]',
'TINT:' => '[int]',
@@ -66,6 +67,7 @@ class mssql extends tools
'mssqlnative' => array(
'INT:' => '[int]',
'BINT' => '[float]',
+ 'ULINT' => '[int]',
'UINT' => '[int]',
'UINT:' => '[int]',
'TINT:' => '[int]',
diff --git a/phpBB/phpbb/db/tools/postgres.php b/phpBB/phpbb/db/tools/postgres.php
index 8b61625c3c..e2a4e668a6 100644
--- a/phpBB/phpbb/db/tools/postgres.php
+++ b/phpBB/phpbb/db/tools/postgres.php
@@ -30,6 +30,7 @@ class postgres extends tools
'postgres' => array(
'INT:' => 'INT4',
'BINT' => 'INT8',
+ 'ULINT' => 'INT4', // unsigned
'UINT' => 'INT4', // unsigned
'UINT:' => 'INT4', // unsigned
'USINT' => 'INT2', // unsigned
diff --git a/phpBB/phpbb/db/tools/tools.php b/phpBB/phpbb/db/tools/tools.php
index b18df1b277..37ac0d0468 100644
--- a/phpBB/phpbb/db/tools/tools.php
+++ b/phpBB/phpbb/db/tools/tools.php
@@ -46,6 +46,7 @@ class tools implements tools_interface
'mysql_41' => array(
'INT:' => 'int(%d)',
'BINT' => 'bigint(20)',
+ 'ULINT' => 'INT(10) UNSIGNED',
'UINT' => 'mediumint(8) UNSIGNED',
'UINT:' => 'int(%d) UNSIGNED',
'TINT:' => 'tinyint(%d)',
@@ -76,6 +77,7 @@ class tools implements tools_interface
'mysql_40' => array(
'INT:' => 'int(%d)',
'BINT' => 'bigint(20)',
+ 'ULINT' => 'INT(10) UNSIGNED',
'UINT' => 'mediumint(8) UNSIGNED',
'UINT:' => 'int(%d) UNSIGNED',
'TINT:' => 'tinyint(%d)',
@@ -106,6 +108,7 @@ class tools implements tools_interface
'oracle' => array(
'INT:' => 'number(%d)',
'BINT' => 'number(20)',
+ 'ULINT' => 'number(10)',
'UINT' => 'number(8)',
'UINT:' => 'number(%d)',
'TINT:' => 'number(%d)',
@@ -136,11 +139,12 @@ class tools implements tools_interface
'sqlite' => array(
'INT:' => 'int(%d)',
'BINT' => 'bigint(20)',
- 'UINT' => 'INTEGER UNSIGNED', //'mediumint(8) UNSIGNED',
+ 'ULINT' => 'INTEGER UNSIGNED', // 'int(10) UNSIGNED',
+ 'UINT' => 'INTEGER UNSIGNED', // 'mediumint(8) UNSIGNED',
'UINT:' => 'INTEGER UNSIGNED', // 'int(%d) UNSIGNED',
'TINT:' => 'tinyint(%d)',
- 'USINT' => 'INTEGER UNSIGNED', //'mediumint(4) UNSIGNED',
- 'BOOL' => 'INTEGER UNSIGNED', //'tinyint(1) UNSIGNED',
+ 'USINT' => 'INTEGER UNSIGNED', // 'mediumint(4) UNSIGNED',
+ 'BOOL' => 'INTEGER UNSIGNED', // 'tinyint(1) UNSIGNED',
'VCHAR' => 'varchar(255)',
'VCHAR:' => 'varchar(%d)',
'CHAR:' => 'char(%d)',
@@ -152,7 +156,7 @@ class tools implements tools_interface
'STEXT_UNI' => 'text(65535)',
'TEXT_UNI' => 'text(65535)',
'MTEXT_UNI' => 'mediumtext(16777215)',
- 'TIMESTAMP' => 'INTEGER UNSIGNED', //'int(11) UNSIGNED',
+ 'TIMESTAMP' => 'INTEGER UNSIGNED', // 'int(11) UNSIGNED',
'DECIMAL' => 'decimal(5,2)',
'DECIMAL:' => 'decimal(%d,2)',
'PDECIMAL' => 'decimal(6,3)',
@@ -166,6 +170,7 @@ class tools implements tools_interface
'sqlite3' => array(
'INT:' => 'INT(%d)',
'BINT' => 'BIGINT(20)',
+ 'ULINT' => 'INTEGER UNSIGNED',
'UINT' => 'INTEGER UNSIGNED',
'UINT:' => 'INTEGER UNSIGNED',
'TINT:' => 'TINYINT(%d)',
@@ -199,7 +204,7 @@ class tools implements tools_interface
* A list of types being unsigned for better reference in some db's
* @var array
*/
- var $unsigned_types = array('UINT', 'UINT:', 'USINT', 'BOOL', 'TIMESTAMP');
+ var $unsigned_types = array('ULINT', 'UINT', 'UINT:', 'USINT', 'BOOL', 'TIMESTAMP');
/**
* This is set to true if user only wants to return the 'to-be-executed' SQL statement(s) (as an array).