From 22ebb24e8221b40ccc44982863bf3c75e6c6fba7 Mon Sep 17 00:00:00 2001 From: Keenan Jaenicke Date: Thu, 15 Feb 2018 14:41:39 -0500 Subject: [PATCH 1/2] adds handling for mssql timestamp cols --- src/drivers/MssqlDriver.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/drivers/MssqlDriver.ts b/src/drivers/MssqlDriver.ts index 237c05a..fb337e2 100644 --- a/src/drivers/MssqlDriver.ts +++ b/src/drivers/MssqlDriver.ts @@ -130,6 +130,9 @@ export class MssqlDriver extends AbstractDriver { case "datetime": colInfo.ts_type = "Date"; break; + case "timestamp": + colInfo.ts_type = "Date"; + break; case "char": colInfo.ts_type = "string"; colInfo.char_max_lenght = From 286c290ad3808372b5db9fc70eddb10661287f0a Mon Sep 17 00:00:00 2001 From: Kononnable Date: Sun, 18 Feb 2018 23:36:07 +0100 Subject: [PATCH 2/2] added test for mssql timestam column --- test/integration/entityTypes/mssql/entity/Post.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/test/integration/entityTypes/mssql/entity/Post.ts b/test/integration/entityTypes/mssql/entity/Post.ts index 39311cf..923be11 100644 --- a/test/integration/entityTypes/mssql/entity/Post.ts +++ b/test/integration/entityTypes/mssql/entity/Post.ts @@ -105,6 +105,9 @@ export class Post { @Column("time") timeObj: Date; + @Column("timestamp") + timestamp: Date; + // @Column("time") // time: string;