@prisma/adapter-mariadb 6.17.0-dev.27 → 6.17.0-dev.29
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/dist/index.js +6 -1
- package/dist/index.mjs +6 -1
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -84,7 +84,10 @@ function mapColumnType(field) {
|
|
|
84
84
|
case "BLOB" /* BLOB */:
|
|
85
85
|
case "TINY_BLOB" /* TINY_BLOB */:
|
|
86
86
|
case "MEDIUM_BLOB" /* MEDIUM_BLOB */:
|
|
87
|
-
|
|
87
|
+
case "LONG_BLOB" /* LONG_BLOB */:
|
|
88
|
+
if (field["dataTypeFormat"] === "json") {
|
|
89
|
+
return import_driver_adapter_utils.ColumnTypeEnum.Json;
|
|
90
|
+
} else if (field.flags.valueOf() & BINARY_FLAG) {
|
|
88
91
|
return import_driver_adapter_utils.ColumnTypeEnum.Bytes;
|
|
89
92
|
} else {
|
|
90
93
|
return import_driver_adapter_utils.ColumnTypeEnum.Text;
|
|
@@ -333,6 +336,8 @@ var MariaDbQueryable = class {
|
|
|
333
336
|
sql,
|
|
334
337
|
rowsAsArray: true,
|
|
335
338
|
dateStrings: true,
|
|
339
|
+
// Disable automatic conversion of JSON blobs to objects.
|
|
340
|
+
autoJsonMap: false,
|
|
336
341
|
// Return JSON strings as strings, not objects.
|
|
337
342
|
// Available in the driver, but not provided in the typings.
|
|
338
343
|
jsonStrings: true,
|
package/dist/index.mjs
CHANGED
|
@@ -48,7 +48,10 @@ function mapColumnType(field) {
|
|
|
48
48
|
case "BLOB" /* BLOB */:
|
|
49
49
|
case "TINY_BLOB" /* TINY_BLOB */:
|
|
50
50
|
case "MEDIUM_BLOB" /* MEDIUM_BLOB */:
|
|
51
|
-
|
|
51
|
+
case "LONG_BLOB" /* LONG_BLOB */:
|
|
52
|
+
if (field["dataTypeFormat"] === "json") {
|
|
53
|
+
return ColumnTypeEnum.Json;
|
|
54
|
+
} else if (field.flags.valueOf() & BINARY_FLAG) {
|
|
52
55
|
return ColumnTypeEnum.Bytes;
|
|
53
56
|
} else {
|
|
54
57
|
return ColumnTypeEnum.Text;
|
|
@@ -297,6 +300,8 @@ var MariaDbQueryable = class {
|
|
|
297
300
|
sql,
|
|
298
301
|
rowsAsArray: true,
|
|
299
302
|
dateStrings: true,
|
|
303
|
+
// Disable automatic conversion of JSON blobs to objects.
|
|
304
|
+
autoJsonMap: false,
|
|
300
305
|
// Return JSON strings as strings, not objects.
|
|
301
306
|
// Available in the driver, but not provided in the typings.
|
|
302
307
|
jsonStrings: true,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@prisma/adapter-mariadb",
|
|
3
|
-
"version": "6.17.0-dev.
|
|
3
|
+
"version": "6.17.0-dev.29",
|
|
4
4
|
"description": "Prisma's driver adapter for \"mariadb\"",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
"sideEffects": false,
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"mariadb": "3.4.5",
|
|
35
|
-
"@prisma/driver-adapter-utils": "6.17.0-dev.
|
|
35
|
+
"@prisma/driver-adapter-utils": "6.17.0-dev.29"
|
|
36
36
|
},
|
|
37
37
|
"scripts": {
|
|
38
38
|
"dev": "DEV=true tsx helpers/build.ts",
|