Skip to content

Commit f1e275d

Browse files
Médéric Ribreuxrldhont
Médéric Ribreux
authored andcommitted
DBManager: support timestamp values for Oracle
1 parent 7509608 commit f1e275d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

python/plugins/db_manager/db_plugins/oracle/data_model.py

+3
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,9 @@ def _sanitizeTableField(self, field):
6464
if field.dataType.upper() == u"DATE":
6565
return u"CAST({} AS VARCHAR2(8))".format(
6666
self.db.quoteId(field.name))
67+
if u"TIMESTAMP" in field.dataType.upper():
68+
return u"TO_CHAR({}, 'YYYY-MM-DD HH:MI:SS.FF')".format(
69+
self.db.quoteId(field.name))
6770
if field.dataType.upper() == u"NUMBER":
6871
if not field.charMaxLen:
6972
return u"CAST({} AS VARCHAR2(135))".format(

0 commit comments

Comments
 (0)