diff --git a/code/MSSQLDatabase.php b/code/MSSQLDatabase.php index ee742cb..92a6ba8 100644 --- a/code/MSSQLDatabase.php +++ b/code/MSSQLDatabase.php @@ -1046,6 +1046,20 @@ class MSSQLDatabase extends SS_Database { return 'RAND()'; } + /** + * This is a lookup table for data types. + * + * For instance, MSSQL uses 'BIGINT', while MySQL uses 'UNSIGNED' + * and PostgreSQL uses 'INT'. + */ + function dbDataType($type){ + $values = array( + 'unsigned integer'=>'BIGINT' + ); + if(isset($values[$type])) return $values[$type]; + else return ''; + } + /** * Convert a SQLQuery object into a SQL statement. */