drizzle-orm-sqlite
Advanced tools
Comparing version 0.12.0-beta.19 to 0.12.0-beta.20
@@ -38,3 +38,3 @@ "use strict"; | ||
if (!fields) { | ||
throw new Error('Statement does not return any data - use run()'); | ||
return this.stmt.all(...this.params); | ||
} | ||
@@ -46,14 +46,11 @@ const values = this.values(placeholderValues); | ||
const { fields } = this; | ||
if (!fields) { | ||
throw new Error('Statement does not return any data - use run()'); | ||
} | ||
const params = (0, sql_1.fillPlaceholders)(this.params, placeholderValues !== null && placeholderValues !== void 0 ? placeholderValues : {}); | ||
this.logger.logQuery(this.queryString, params); | ||
const value = this.stmt.raw().get(...params); | ||
if (!fields) { | ||
return value; | ||
} | ||
return (0, utils_1.mapResultRowV2)(fields, value); | ||
} | ||
values(placeholderValues) { | ||
if (!this.fields) { | ||
throw new Error('Statement does not return any data - use run()'); | ||
} | ||
const params = (0, sql_1.fillPlaceholders)(this.params, placeholderValues !== null && placeholderValues !== void 0 ? placeholderValues : {}); | ||
@@ -60,0 +57,0 @@ this.logger.logQuery(this.queryString, params); |
@@ -224,3 +224,2 @@ "use strict"; | ||
)`; | ||
yield session.run((0, drizzle_orm_1.sql) `CREATE SCHEMA IF NOT EXISTS "drizzle"`); | ||
yield session.run(migrationTableCreate); | ||
@@ -227,0 +226,0 @@ const dbMigrations = yield session.values((0, drizzle_orm_1.sql) `SELECT id, hash, created_at FROM "__drizzle_migrations" ORDER BY created_at DESC LIMIT 1`); |
{ | ||
"name": "drizzle-orm-sqlite", | ||
"version": "0.12.0-beta.19", | ||
"version": "0.12.0-beta.20", | ||
"description": "Drizzle ORM package for SQLite database", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
180228
2658