Note:

If you want to create a new page for developers, you should create it on the Moodle Developer Resource site.

XMLDB column types: Difference between revisions

From MoodleDocs
(FIELD TYPE "date with time" changed to "datetime")
mNo edit summary
Line 1: Line 1:
[[XML database schema]] > XMLDB column types
[[XML database schema]] > [[XMLDB Documentation|Documentation]] > XMLDB column types
----
----
This page will show, once finished, one compatibility matrix of column types for each of the RDBMS under which Moodle is expected to work.
This page will show, once finished, one compatibility matrix of column types for each of the RDBMS under which Moodle is expected to work.

Revision as of 16:37, 28 February 2007

XML database schema > Documentation > XMLDB column types


This page will show, once finished, one compatibility matrix of column types for each of the RDBMS under which Moodle is expected to work.

The matrix

XMLDB Type MySQL PostgreSQL Oracle MSSQL
int
BIGINT (>9 digits)
INT (>6 digits)
MEDIUMINT (>4 digits)
SMALLINT (>2 digits)
TINYINT (<=2 digits)
BIGINT (>9 digits)
INTEGER (>4 digits)
SMALLINT (<=4 digits)
NUMBER
BIGINT (>9 digits)
INTEGER (>4 digits)
SMALLINT (<=4 digits)
number
NUMERIC
NUMERIC
NUMBER
DECIMAL
float
FLOAT (< 6 dec. positions)
DOUBLE (>= 6 dec. positions)
REAL (< 6 dec. positions)
DOUBLE PRECISION (>= 6 dec. positions)
NUMBER
REAL (< 6 dec. positions)
FLOAT (>= 6 dec. positions)
char
VARCHAR
VARCHAR
VARCHAR2
NVARCHAR
text
LONGTEXT
MEDIUMTEXT
TEXT
TEXT
CLOB
NTEXT
binary
LONGBLOB
MEDIUMBLOB
BLOB
BYTEA
BLOB
IMAGE
datetime
DATETIME
TIMESTAMP
DATE
DATETIME

Some official links