mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-26 14:26:00 +00:00
fix: correctly map DuckDBTimeValue to string
This commit is contained in:
@@ -55,10 +55,11 @@ function _normalizeValue(value) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (value instanceof DuckDBTimeValue) {
|
if (value instanceof DuckDBTimeValue) {
|
||||||
const hour = String(value.hour).padStart(2, '0');
|
const parts = value.toParts();
|
||||||
const minute = String(value.min).padStart(2, '0');
|
const hour = String(parts.hour).padStart(2, '0');
|
||||||
const second = String(value.sec).padStart(2, '0');
|
const minute = String(parts.min).padStart(2, '0');
|
||||||
const micros = String(value.micros).padStart(6, '0').substring(0, 3);
|
const second = String(parts.sec).padStart(2, '0');
|
||||||
|
const micros = String(parts.micros).padStart(6, '0').substring(0, 3);
|
||||||
return `${hour}:${minute}:${second}.${micros}`;
|
return `${hour}:${minute}:${second}.${micros}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user