pgsql-deparser 17.9.0 → 17.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/deparser.js +18 -0
- package/esm/deparser.js +18 -0
- package/package.json +2 -2
package/deparser.js
CHANGED
|
@@ -1711,6 +1711,24 @@ class Deparser {
|
|
|
1711
1711
|
typeName = 'time with time zone';
|
|
1712
1712
|
}
|
|
1713
1713
|
}
|
|
1714
|
+
else if (type === 'timestamp') {
|
|
1715
|
+
if (args) {
|
|
1716
|
+
typeName = `timestamp(${args})`;
|
|
1717
|
+
args = null; // Don't apply args again in mods()
|
|
1718
|
+
}
|
|
1719
|
+
else {
|
|
1720
|
+
typeName = 'timestamp';
|
|
1721
|
+
}
|
|
1722
|
+
}
|
|
1723
|
+
else if (type === 'time') {
|
|
1724
|
+
if (args) {
|
|
1725
|
+
typeName = `time(${args})`;
|
|
1726
|
+
args = null; // Don't apply args again in mods()
|
|
1727
|
+
}
|
|
1728
|
+
else {
|
|
1729
|
+
typeName = 'time';
|
|
1730
|
+
}
|
|
1731
|
+
}
|
|
1714
1732
|
let result = mods(typeName, args);
|
|
1715
1733
|
if (node.arrayBounds && node.arrayBounds.length > 0) {
|
|
1716
1734
|
result += formatArrayBounds(node.arrayBounds);
|
package/esm/deparser.js
CHANGED
|
@@ -1708,6 +1708,24 @@ export class Deparser {
|
|
|
1708
1708
|
typeName = 'time with time zone';
|
|
1709
1709
|
}
|
|
1710
1710
|
}
|
|
1711
|
+
else if (type === 'timestamp') {
|
|
1712
|
+
if (args) {
|
|
1713
|
+
typeName = `timestamp(${args})`;
|
|
1714
|
+
args = null; // Don't apply args again in mods()
|
|
1715
|
+
}
|
|
1716
|
+
else {
|
|
1717
|
+
typeName = 'timestamp';
|
|
1718
|
+
}
|
|
1719
|
+
}
|
|
1720
|
+
else if (type === 'time') {
|
|
1721
|
+
if (args) {
|
|
1722
|
+
typeName = `time(${args})`;
|
|
1723
|
+
args = null; // Don't apply args again in mods()
|
|
1724
|
+
}
|
|
1725
|
+
else {
|
|
1726
|
+
typeName = 'time';
|
|
1727
|
+
}
|
|
1728
|
+
}
|
|
1711
1729
|
let result = mods(typeName, args);
|
|
1712
1730
|
if (node.arrayBounds && node.arrayBounds.length > 0) {
|
|
1713
1731
|
result += formatArrayBounds(node.arrayBounds);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pgsql-deparser",
|
|
3
|
-
"version": "17.9.
|
|
3
|
+
"version": "17.9.1",
|
|
4
4
|
"author": "Dan Lynch <pyramation@gmail.com>",
|
|
5
5
|
"description": "PostgreSQL AST Deparser",
|
|
6
6
|
"main": "index.js",
|
|
@@ -58,5 +58,5 @@
|
|
|
58
58
|
"dependencies": {
|
|
59
59
|
"@pgsql/types": "^17.6.1"
|
|
60
60
|
},
|
|
61
|
-
"gitHead": "
|
|
61
|
+
"gitHead": "ec88c0497ed19b222655ab8dba6a2f1ca1350fee"
|
|
62
62
|
}
|