typeorm 0.2.45-dev.ea16ac2 → 0.2.45-dev.f3cfdd2
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/browser/decorator/options/ViewColumnOptions.d.ts +6 -0
- package/browser/decorator/options/ViewColumnOptions.js.map +1 -1
- package/browser/driver/aurora-data-api/AuroraDataApiQueryRunner.js +21 -14
- package/browser/driver/aurora-data-api/AuroraDataApiQueryRunner.js.map +1 -1
- package/browser/driver/cockroachdb/CockroachQueryRunner.js +19 -13
- package/browser/driver/cockroachdb/CockroachQueryRunner.js.map +1 -1
- package/browser/driver/mysql/MysqlQueryRunner.js +21 -14
- package/browser/driver/mysql/MysqlQueryRunner.js.map +1 -1
- package/browser/driver/oracle/OracleQueryRunner.js +21 -14
- package/browser/driver/oracle/OracleQueryRunner.js.map +1 -1
- package/browser/driver/postgres/PostgresQueryRunner.js +19 -13
- package/browser/driver/postgres/PostgresQueryRunner.js.map +1 -1
- package/browser/driver/sap/SapQueryRunner.js +19 -13
- package/browser/driver/sap/SapQueryRunner.js.map +1 -1
- package/browser/driver/sqlite-abstract/AbstractSqliteQueryRunner.js +21 -15
- package/browser/driver/sqlite-abstract/AbstractSqliteQueryRunner.js.map +1 -1
- package/browser/driver/sqlserver/SqlServerQueryRunner.js +23 -15
- package/browser/driver/sqlserver/SqlServerQueryRunner.js.map +1 -1
- package/browser/naming-strategy/DefaultNamingStrategy.d.ts +1 -1
- package/browser/naming-strategy/DefaultNamingStrategy.js.map +1 -1
- package/decorator/options/ViewColumnOptions.d.ts +6 -0
- package/decorator/options/ViewColumnOptions.js.map +1 -1
- package/driver/aurora-data-api/AuroraDataApiQueryRunner.js +21 -14
- package/driver/aurora-data-api/AuroraDataApiQueryRunner.js.map +1 -1
- package/driver/cockroachdb/CockroachQueryRunner.js +19 -13
- package/driver/cockroachdb/CockroachQueryRunner.js.map +1 -1
- package/driver/mysql/MysqlQueryRunner.js +21 -14
- package/driver/mysql/MysqlQueryRunner.js.map +1 -1
- package/driver/oracle/OracleQueryRunner.js +21 -14
- package/driver/oracle/OracleQueryRunner.js.map +1 -1
- package/driver/postgres/PostgresQueryRunner.js +19 -13
- package/driver/postgres/PostgresQueryRunner.js.map +1 -1
- package/driver/sap/SapQueryRunner.js +19 -13
- package/driver/sap/SapQueryRunner.js.map +1 -1
- package/driver/sqlite-abstract/AbstractSqliteQueryRunner.js +21 -15
- package/driver/sqlite-abstract/AbstractSqliteQueryRunner.js.map +1 -1
- package/driver/sqlserver/SqlServerQueryRunner.js +23 -15
- package/driver/sqlserver/SqlServerQueryRunner.js.map +1 -1
- package/naming-strategy/DefaultNamingStrategy.d.ts +1 -1
- package/naming-strategy/DefaultNamingStrategy.js.map +1 -1
- package/package.json +1 -1
|
@@ -1767,16 +1767,19 @@ var OracleQueryRunner = /** @class */ (function (_super) {
|
|
|
1767
1767
|
*/
|
|
1768
1768
|
OracleQueryRunner.prototype.clearDatabase = function () {
|
|
1769
1769
|
return __awaiter(this, void 0, void 0, function () {
|
|
1770
|
-
var dropViewsQuery, dropViewQueries, dropMatViewsQuery, dropMatViewQueries, dropTablesQuery, dropTableQueries, error_1, rollbackError_1;
|
|
1770
|
+
var isAnotherTransactionActive, dropViewsQuery, dropViewQueries, dropMatViewsQuery, dropMatViewQueries, dropTablesQuery, dropTableQueries, error_1, rollbackError_1;
|
|
1771
1771
|
var _this = this;
|
|
1772
1772
|
return __generator(this, function (_a) {
|
|
1773
1773
|
switch (_a.label) {
|
|
1774
|
-
case 0:
|
|
1774
|
+
case 0:
|
|
1775
|
+
isAnotherTransactionActive = this.isTransactionActive;
|
|
1776
|
+
if (!!isAnotherTransactionActive) return [3 /*break*/, 2];
|
|
1777
|
+
return [4 /*yield*/, this.startTransaction()];
|
|
1775
1778
|
case 1:
|
|
1776
1779
|
_a.sent();
|
|
1777
1780
|
_a.label = 2;
|
|
1778
1781
|
case 2:
|
|
1779
|
-
_a.trys.push([2,
|
|
1782
|
+
_a.trys.push([2, 11, , 17]);
|
|
1780
1783
|
dropViewsQuery = "SELECT 'DROP VIEW \"' || VIEW_NAME || '\"' AS \"query\" FROM \"USER_VIEWS\"";
|
|
1781
1784
|
return [4 /*yield*/, this.query(dropViewsQuery)];
|
|
1782
1785
|
case 3:
|
|
@@ -1798,24 +1801,28 @@ var OracleQueryRunner = /** @class */ (function (_super) {
|
|
|
1798
1801
|
return [4 /*yield*/, Promise.all(dropTableQueries.map(function (query) { return _this.query(query["query"]); }))];
|
|
1799
1802
|
case 8:
|
|
1800
1803
|
_a.sent();
|
|
1804
|
+
if (!!isAnotherTransactionActive) return [3 /*break*/, 10];
|
|
1801
1805
|
return [4 /*yield*/, this.commitTransaction()];
|
|
1802
1806
|
case 9:
|
|
1803
1807
|
_a.sent();
|
|
1804
|
-
|
|
1805
|
-
case 10:
|
|
1806
|
-
error_1 = _a.sent();
|
|
1807
|
-
_a.label = 11;
|
|
1808
|
+
_a.label = 10;
|
|
1809
|
+
case 10: return [3 /*break*/, 17];
|
|
1808
1810
|
case 11:
|
|
1809
|
-
_a.
|
|
1810
|
-
|
|
1811
|
+
error_1 = _a.sent();
|
|
1812
|
+
_a.label = 12;
|
|
1811
1813
|
case 12:
|
|
1812
|
-
_a.
|
|
1813
|
-
return [3 /*break*/, 14];
|
|
1814
|
+
_a.trys.push([12, 15, , 16]);
|
|
1815
|
+
if (!!isAnotherTransactionActive) return [3 /*break*/, 14];
|
|
1816
|
+
return [4 /*yield*/, this.rollbackTransaction()];
|
|
1814
1817
|
case 13:
|
|
1818
|
+
_a.sent();
|
|
1819
|
+
_a.label = 14;
|
|
1820
|
+
case 14: return [3 /*break*/, 16];
|
|
1821
|
+
case 15:
|
|
1815
1822
|
rollbackError_1 = _a.sent();
|
|
1816
|
-
return [3 /*break*/,
|
|
1817
|
-
case
|
|
1818
|
-
case
|
|
1823
|
+
return [3 /*break*/, 16];
|
|
1824
|
+
case 16: throw error_1;
|
|
1825
|
+
case 17: return [2 /*return*/];
|
|
1819
1826
|
}
|
|
1820
1827
|
});
|
|
1821
1828
|
});
|