pqb 0.31.1 → 0.31.3
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.d.ts +5 -4
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2994,6 +2994,7 @@ if (process.versions.bun) {
|
|
|
2994
2994
|
};
|
|
2995
2995
|
}
|
|
2996
2996
|
Object.defineProperty(Then.prototype, "then", {
|
|
2997
|
+
configurable: true,
|
|
2997
2998
|
get: getThen,
|
|
2998
2999
|
set(value) {
|
|
2999
3000
|
Object.defineProperty(this, "then", {
|
|
@@ -5359,6 +5360,7 @@ class TransactionAdapter {
|
|
|
5359
5360
|
this.types = types2;
|
|
5360
5361
|
this.pool = adapter.pool;
|
|
5361
5362
|
this.config = adapter.config;
|
|
5363
|
+
this.schema = adapter.schema;
|
|
5362
5364
|
}
|
|
5363
5365
|
connect() {
|
|
5364
5366
|
return Promise.resolve(this.client);
|
|
@@ -6605,18 +6607,18 @@ class Create {
|
|
|
6605
6607
|
*
|
|
6606
6608
|
* // single column:
|
|
6607
6609
|
* // (this requires a composite primary key or unique index, see below)
|
|
6608
|
-
* db.table.create(data).
|
|
6610
|
+
* db.table.create(data).onConflict('email').merge();
|
|
6609
6611
|
*
|
|
6610
6612
|
* // array of columns:
|
|
6611
|
-
* db.table.create(data).
|
|
6613
|
+
* db.table.create(data).onConflict(['email', 'name']).merge();
|
|
6612
6614
|
*
|
|
6613
6615
|
* // constraint name
|
|
6614
|
-
* db.table.create(data).
|
|
6616
|
+
* db.table.create(data).onConflict({ constraint: 'unique_index_name' }).merge();
|
|
6615
6617
|
*
|
|
6616
6618
|
* // raw SQL expression:
|
|
6617
6619
|
* db.table
|
|
6618
6620
|
* .create(data)
|
|
6619
|
-
* .
|
|
6621
|
+
* .onConflict(sql`(email) where condition`)
|
|
6620
6622
|
* .merge();
|
|
6621
6623
|
* ```
|
|
6622
6624
|
*
|