@dbml/connector 5.1.0 → 5.3.0
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/__tests__/connector.test.ts +1 -1
- package/__tests__/connectors/mssql/expect-out-files/schema.json +98 -7
- package/__tests__/connectors/mssql/out-files/schema.json +2165 -0
- package/__tests__/connectors/mysql/expect-out-files/schema.json +99 -9
- package/__tests__/connectors/mysql/out-files/schema.json +1520 -0
- package/__tests__/connectors/oracle/connection.json +4 -0
- package/__tests__/connectors/oracle/expect-out-files/schema.json +3866 -0
- package/__tests__/connectors/oracle/out-files/schema.json +3866 -0
- package/__tests__/connectors/postgres/expect-out-files/schema.json +119 -8
- package/__tests__/connectors/postgres/out-files/schema.json +1830 -0
- package/dist/connectors/{bigqueryConnector.d.ts → bigquery/index.d.ts} +1 -1
- package/dist/connectors/{bigqueryConnector.js → bigquery/index.js} +3 -4
- package/dist/connectors/connector.js +13 -10
- package/dist/connectors/{snowflakeConnector.d.ts → mssql/index.d.ts} +1 -1
- package/dist/connectors/{mssqlConnector.js → mssql/index.js} +13 -10
- package/dist/connectors/{mysqlConnector.d.ts → mysql/index.d.ts} +1 -1
- package/dist/connectors/{mysqlConnector.js → mysql/index.js} +1 -1
- package/dist/connectors/oracle/constraints.d.ts +7 -0
- package/dist/connectors/oracle/constraints.js +112 -0
- package/dist/connectors/oracle/index.d.ts +3 -0
- package/dist/connectors/oracle/index.js +68 -0
- package/dist/connectors/oracle/indexes.d.ts +3 -0
- package/dist/connectors/oracle/indexes.js +65 -0
- package/dist/connectors/oracle/refs.d.ts +3 -0
- package/dist/connectors/oracle/refs.js +67 -0
- package/dist/connectors/oracle/tables.d.ts +7 -0
- package/dist/connectors/oracle/tables.js +280 -0
- package/dist/connectors/oracle/utils.d.ts +9 -0
- package/dist/connectors/oracle/utils.js +27 -0
- package/dist/connectors/{postgresConnector.d.ts → postgres/index.d.ts} +1 -1
- package/dist/connectors/{postgresConnector.js → postgres/index.js} +21 -16
- package/dist/connectors/{mssqlConnector.d.ts → snowflake/index.d.ts} +1 -1
- package/dist/connectors/{snowflakeConnector.js → snowflake/index.js} +1 -2
- package/dist/connectors/types.d.ts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +17 -7
- package/dist/utils/parseSchema.d.ts +1 -1
- package/dist/utils/parseSchema.js +13 -13
- package/eslint.config.ts +70 -0
- package/jest.config.ts +2 -2
- package/package.json +17 -6
- package/src/connectors/{bigqueryConnector.ts → bigquery/index.ts} +4 -5
- package/src/connectors/connector.ts +8 -5
- package/src/connectors/{mssqlConnector.ts → mssql/index.ts} +20 -15
- package/src/connectors/{mysqlConnector.ts → mysql/index.ts} +3 -3
- package/src/connectors/oracle/constraints.ts +113 -0
- package/src/connectors/oracle/index.ts +76 -0
- package/src/connectors/oracle/indexes.ts +71 -0
- package/src/connectors/oracle/refs.ts +73 -0
- package/src/connectors/oracle/tables.ts +305 -0
- package/src/connectors/oracle/utils.ts +23 -0
- package/src/connectors/{postgresConnector.ts → postgres/index.ts} +25 -18
- package/src/connectors/{snowflakeConnector.ts → snowflake/index.ts} +7 -6
- package/src/connectors/types.ts +14 -13
- package/src/index.ts +1 -1
- package/src/utils/parseSchema.ts +11 -11
- package/tsconfig.json +1 -1
- package/.eslintrc.json +0 -24
|
@@ -84,6 +84,13 @@
|
|
|
84
84
|
"value": "This table stores information about various items."
|
|
85
85
|
}
|
|
86
86
|
},
|
|
87
|
+
{
|
|
88
|
+
"name": "table_with_composite_primary_and_unique_indexes",
|
|
89
|
+
"schemaName": "dbo",
|
|
90
|
+
"note": {
|
|
91
|
+
"value": ""
|
|
92
|
+
}
|
|
93
|
+
},
|
|
87
94
|
{
|
|
88
95
|
"name": "Authors",
|
|
89
96
|
"schemaName": "dbo",
|
|
@@ -1416,6 +1423,60 @@
|
|
|
1416
1423
|
}
|
|
1417
1424
|
}
|
|
1418
1425
|
],
|
|
1426
|
+
"dbo.table_with_composite_primary_and_unique_indexes": [
|
|
1427
|
+
{
|
|
1428
|
+
"name": "col1",
|
|
1429
|
+
"type": {
|
|
1430
|
+
"type_name": "int(10)",
|
|
1431
|
+
"schemaName": null
|
|
1432
|
+
},
|
|
1433
|
+
"dbdefault": null,
|
|
1434
|
+
"not_null": true,
|
|
1435
|
+
"increment": false,
|
|
1436
|
+
"note": {
|
|
1437
|
+
"value": ""
|
|
1438
|
+
}
|
|
1439
|
+
},
|
|
1440
|
+
{
|
|
1441
|
+
"name": "col2",
|
|
1442
|
+
"type": {
|
|
1443
|
+
"type_name": "int(10)",
|
|
1444
|
+
"schemaName": null
|
|
1445
|
+
},
|
|
1446
|
+
"dbdefault": null,
|
|
1447
|
+
"not_null": true,
|
|
1448
|
+
"increment": false,
|
|
1449
|
+
"note": {
|
|
1450
|
+
"value": ""
|
|
1451
|
+
}
|
|
1452
|
+
},
|
|
1453
|
+
{
|
|
1454
|
+
"name": "col3",
|
|
1455
|
+
"type": {
|
|
1456
|
+
"type_name": "int(10)",
|
|
1457
|
+
"schemaName": null
|
|
1458
|
+
},
|
|
1459
|
+
"dbdefault": null,
|
|
1460
|
+
"not_null": false,
|
|
1461
|
+
"increment": false,
|
|
1462
|
+
"note": {
|
|
1463
|
+
"value": ""
|
|
1464
|
+
}
|
|
1465
|
+
},
|
|
1466
|
+
{
|
|
1467
|
+
"name": "col4",
|
|
1468
|
+
"type": {
|
|
1469
|
+
"type_name": "int(10)",
|
|
1470
|
+
"schemaName": null
|
|
1471
|
+
},
|
|
1472
|
+
"dbdefault": null,
|
|
1473
|
+
"not_null": false,
|
|
1474
|
+
"increment": false,
|
|
1475
|
+
"note": {
|
|
1476
|
+
"value": ""
|
|
1477
|
+
}
|
|
1478
|
+
}
|
|
1479
|
+
],
|
|
1419
1480
|
"dbo.Authors": [
|
|
1420
1481
|
{
|
|
1421
1482
|
"name": "AuthorID",
|
|
@@ -1782,7 +1843,9 @@
|
|
|
1782
1843
|
"type": "column",
|
|
1783
1844
|
"value": "product_id"
|
|
1784
1845
|
}
|
|
1785
|
-
]
|
|
1846
|
+
],
|
|
1847
|
+
"pk": false,
|
|
1848
|
+
"unique": false
|
|
1786
1849
|
}
|
|
1787
1850
|
],
|
|
1788
1851
|
"dbo.orders": [
|
|
@@ -1798,7 +1861,9 @@
|
|
|
1798
1861
|
"type": "column",
|
|
1799
1862
|
"value": "order_date"
|
|
1800
1863
|
}
|
|
1801
|
-
]
|
|
1864
|
+
],
|
|
1865
|
+
"pk": false,
|
|
1866
|
+
"unique": false
|
|
1802
1867
|
}
|
|
1803
1868
|
],
|
|
1804
1869
|
"dbo.products": [
|
|
@@ -1810,7 +1875,9 @@
|
|
|
1810
1875
|
"type": "column",
|
|
1811
1876
|
"value": "category"
|
|
1812
1877
|
}
|
|
1813
|
-
]
|
|
1878
|
+
],
|
|
1879
|
+
"pk": false,
|
|
1880
|
+
"unique": false
|
|
1814
1881
|
}
|
|
1815
1882
|
],
|
|
1816
1883
|
"dbo.users": [
|
|
@@ -1822,7 +1889,9 @@
|
|
|
1822
1889
|
"type": "column",
|
|
1823
1890
|
"value": "email"
|
|
1824
1891
|
}
|
|
1825
|
-
]
|
|
1892
|
+
],
|
|
1893
|
+
"pk": false,
|
|
1894
|
+
"unique": false
|
|
1826
1895
|
},
|
|
1827
1896
|
{
|
|
1828
1897
|
"name": "idx_users_full_name",
|
|
@@ -1832,7 +1901,9 @@
|
|
|
1832
1901
|
"type": "column",
|
|
1833
1902
|
"value": "full_name"
|
|
1834
1903
|
}
|
|
1835
|
-
]
|
|
1904
|
+
],
|
|
1905
|
+
"pk": false,
|
|
1906
|
+
"unique": false
|
|
1836
1907
|
},
|
|
1837
1908
|
{
|
|
1838
1909
|
"name": "idx_users_is_active_full_name",
|
|
@@ -1846,7 +1917,9 @@
|
|
|
1846
1917
|
"type": "column",
|
|
1847
1918
|
"value": "full_name_lower"
|
|
1848
1919
|
}
|
|
1849
|
-
]
|
|
1920
|
+
],
|
|
1921
|
+
"pk": false,
|
|
1922
|
+
"unique": false
|
|
1850
1923
|
}
|
|
1851
1924
|
]
|
|
1852
1925
|
},
|
|
@@ -1999,6 +2072,24 @@
|
|
|
1999
2072
|
"pk": true
|
|
2000
2073
|
}
|
|
2001
2074
|
},
|
|
2075
|
+
"dbo.table_with_composite_primary_and_unique_indexes": {
|
|
2076
|
+
"col1": {
|
|
2077
|
+
"checks": [],
|
|
2078
|
+
"pk": true
|
|
2079
|
+
},
|
|
2080
|
+
"col2": {
|
|
2081
|
+
"checks": [],
|
|
2082
|
+
"pk": true
|
|
2083
|
+
},
|
|
2084
|
+
"col3": {
|
|
2085
|
+
"checks": [],
|
|
2086
|
+
"unique": true
|
|
2087
|
+
},
|
|
2088
|
+
"col4": {
|
|
2089
|
+
"checks": [],
|
|
2090
|
+
"unique": true
|
|
2091
|
+
}
|
|
2092
|
+
},
|
|
2002
2093
|
"dbo.user_define_data_types": {
|
|
2003
2094
|
"id": {
|
|
2004
2095
|
"checks": [],
|
|
@@ -2071,4 +2162,4 @@
|
|
|
2071
2162
|
}
|
|
2072
2163
|
]
|
|
2073
2164
|
}
|
|
2074
|
-
}
|
|
2165
|
+
}
|