@travetto/model-postgres 8.0.0-alpha.31 → 8.0.0-alpha.33

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@travetto/model-postgres",
3
- "version": "8.0.0-alpha.31",
3
+ "version": "8.0.0-alpha.33",
4
4
  "type": "module",
5
5
  "description": "PostgreSQL backing for the travetto model module, with real-time modeling support for SQL schemas.",
6
6
  "keywords": [
@@ -28,16 +28,16 @@
28
28
  "directory": "module/model-postgres"
29
29
  },
30
30
  "dependencies": {
31
- "@travetto/config": "^8.0.0-alpha.25",
32
- "@travetto/context": "^8.0.0-alpha.22",
33
- "@travetto/model": "^8.0.0-alpha.26",
34
- "@travetto/model-query": "^8.0.0-alpha.28",
35
- "@travetto/model-sql": "^8.0.0-alpha.31",
36
- "@types/pg": "^8.20.0",
37
- "pg": "^8.22.0"
31
+ "@travetto/config": "^8.0.0-alpha.26",
32
+ "@travetto/context": "^8.0.0-alpha.23",
33
+ "@travetto/model": "^8.0.0-alpha.27",
34
+ "@travetto/model-query": "^8.0.0-alpha.30",
35
+ "@travetto/model-sql": "^8.0.0-alpha.33",
36
+ "@types/pg": "^8.23.1",
37
+ "pg": "^8.23.0"
38
38
  },
39
39
  "peerDependencies": {
40
- "@travetto/cli": "^8.0.0-alpha.31"
40
+ "@travetto/cli": "^8.0.0-alpha.32"
41
41
  },
42
42
  "peerDependenciesMeta": {
43
43
  "@travetto/cli": {
package/src/connection.ts CHANGED
@@ -75,7 +75,7 @@ export class PostgresConnection extends SQLConnection<PoolClient> {
75
75
  async execute<Type = unknown>(query: string, values?: unknown[]): Promise<{ count: number; records: Type[] }> {
76
76
  console.debug('Executing PostgreSQL query', { query, values });
77
77
 
78
- // Handle dynamically built savepoint names that cannot be parameterized in Postgres
78
+ // Handle dynamically built SAVEPOINT names that cannot be parameterized in Postgres
79
79
  if (query.includes('SAVEPOINT') || query.includes('ROLLBACK TO') || query.includes('RELEASE SAVEPOINT')) {
80
80
  if (values && values.length > 0) {
81
81
  query = query.replace('$1', `"${values[0]}"`);
package/src/dialect.ts CHANGED
@@ -2,6 +2,8 @@ import { AbstractANSI99Dialect, type ResolvedPathContext, type TableContext } fr
2
2
  import { type Class, castTo, JSONUtil } from '@travetto/runtime';
3
3
  import { type SchemaFieldConfig, SchemaRegistryIndex } from '@travetto/schema';
4
4
 
5
+ /* cspell:words ILIKE regclass indexdef tablename pkey */
6
+
5
7
  export class PostgresDialect extends AbstractANSI99Dialect {
6
8
  returningSupport = true;
7
9
  suggestLikeOperator = 'ILIKE';
@@ -1,6 +1,6 @@
1
1
  import type { ServiceDescriptor } from '@travetto/cli';
2
2
 
3
- const version = process.env.POSTGRESQL_VERSION || '18.3';
3
+ const version = process.env.POSTGRESQL_VERSION || '18.6';
4
4
 
5
5
  export const service: ServiceDescriptor = {
6
6
  name: 'postgresql',