From 91c09562ed9c6eb1bd3a4dbd84a8cc64647751ee Mon Sep 17 00:00:00 2001 From: Derick Hawcroft Date: Thu, 5 Nov 2009 10:35:48 +1000 Subject: Fix retrieval of SQL type "TIME" information for PostgreSQL PostgreSQL can store/retieve the millisecond part of type "TIME" , so allow it in the API level. Task-number: QTBUG-5251 Reviewed-by: Bill King --- src/sql/drivers/psql/qsql_psql.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/sql') diff --git a/src/sql/drivers/psql/qsql_psql.cpp b/src/sql/drivers/psql/qsql_psql.cpp index 4c78d6a23a..3e3ea06664 100644 --- a/src/sql/drivers/psql/qsql_psql.cpp +++ b/src/sql/drivers/psql/qsql_psql.cpp @@ -1133,7 +1133,7 @@ QString QPSQLDriver::formatValue(const QSqlField &field, bool trimStrings) const case QVariant::Time: #ifndef QT_NO_DATESTRING if (field.value().toTime().isValid()) { - r = QLatin1Char('\'') + field.value().toTime().toString(Qt::ISODate) + QLatin1Char('\''); + r = QLatin1Char('\'') + field.value().toTime().toString(QLatin1String("hh:mm:ss.zzz")) + QLatin1Char('\''); } else #endif { -- cgit v1.2.3