DataTypes

These are the available DataTypes on the Sequelize class. You can access these on the class object as seen here.

Example

var Sequelize = require('sequelize-mock');
var sequelize = new Sequelize();

Sequelize.STRING
// OR ...
sequelize.Sequelize.STRING

STRING

Mock string data type

CHAR

Mock char data type

TEXT

Mock text data type

INTEGER

Mock integer data type

BIGINT

Mock big integer data type

FLOAT

Mock float data type

REAL

Mock real number data type

DOUBLE

Mock double data type

DECIMAL

Mock decimal data type

BOOLEAN

Mock boolean data type

TIME

Mock time data type

DATE

Mock date data type

DATEONLY

Mock date-only data type

HSTORE

Mock hstore data type

JSON

Mock JSON data type

JSONB

Mock JSONB data type

NOW

Mock now datetime data type

BLOB

Mock blob data type

RANGE

Mock range data type

UUID

Mock UUID data type

UUIDV1

Mock UUIDV1 data type

UUIDV4

Mock UUIDV4 data type

VIRTUAL

Mock virutal data type (even though all test types are technically virtual)

ENUM

Mock enum data type

ARRAY

Mock array data type

GEOMETRY

Mock geometry data type

GEOGRAPHY

Mock geography data type