-
-
Notifications
You must be signed in to change notification settings - Fork 6.5k
Description
Issue description
Wrong SQL generated for migration
Expected Behavior
Migration SQL for a concurrent index should look like:
CREATE INDEX CONCURRENTLY "IDX_394bb7197c59f2b0924382db09" ON "connection" ("lastAttemptedAt")
DROP INDEX CONCURRENTLY "public"."IDX_394bb7197c59f2b0924382db09"
Actual Behavior
Incorrect SQL generated
CREATE CONCURRENTLY INDEX "IDX_394bb7197c59f2b0924382db09" ON "connection" ("lastAttemptedAt")
DROP INDEX CONCURRENTLY"public"."IDX_394bb7197c59f2b0924382db09"
(both statements are invalid)
eg query failed: CREATE CONCURRENTLY INDEX "IDX_394bb7197c59f2b0924382db09" ON "connection" ("lastAttemptedAt")
Steps to reproduce
class Connection {
@Index({ concurrent: true})
@column({ type: 'timestamp with time zone', nullable: true })
lastAttemptedAt!: Date | null;
}
My Environment
| Dependency | Version |
|---|---|
| Operating System | OSX 14.1.1 (23B81) |
| Node.js version | 18.18.2 |
| Typescript version | 5.3.3 |
| TypeORM version | 0.3.19 |
Additional Context
No response
Relevant Database Driver(s)
- aurora-mysql
- aurora-postgres
- better-sqlite3
- cockroachdb
- cordova
- expo
- mongodb
- mysql
- nativescript
- oracle
- postgres
- react-native
- sap
- spanner
- sqlite
- sqlite-abstract
- sqljs
- sqlserver
Are you willing to resolve this issue by submitting a Pull Request?
No, I don’t have the time and I’m okay to wait for the community / maintainers to resolve this issue.