{"record":{"id":"9dd79b6ca8d4bd3a","repo":"n8n-io/n8n","slug":"sqlit-driver-does-not-support-change-comment","errorCode":null,"errorMessage":"sqlit driver does not support change comment.","messagePattern":"sqlit driver does not support change comment\\.","errorType":"exception","errorClass":"TypeORMError","httpStatus":null,"severity":"error","filePath":"packages/@n8n/typeorm/src/driver/sqlite-abstract/AbstractSqliteQueryRunner.ts","lineNumber":1953,"sourceCode":"\n\t/**\n\t * Escapes given table or view path. Tolerates leading/trailing dots\n\t */\n\tprotected escapePath(target: Table | View | string, disableEscape?: boolean): string {\n\t\tconst tableName =\n\t\t\tInstanceChecker.isTable(target) || InstanceChecker.isView(target) ? target.name : target;\n\t\treturn tableName\n\t\t\t.replace(/^\\.+|\\.+$/g, '')\n\t\t\t.split('.')\n\t\t\t.map((i) => (disableEscape ? i : `\"${i.replace(/\"/g, '\"\"')}\"`))\n\t\t\t.join('.');\n\t}\n\n\t/**\n\t * Change table comment.\n\t */\n\tchangeTableComment(tableOrName: Table | string, comment?: string): Promise<void> {\n\t\tthrow new TypeORMError(`sqlit driver does not support change comment.`);\n\t}\n}\n","sourceCodeStart":1935,"sourceCodeEnd":1956,"githubUrl":"https://github.com/n8n-io/n8n/blob/5ac6606e81f67bb9534255570cd4e86fd8101eee/packages/@n8n/typeorm/src/driver/sqlite-abstract/AbstractSqliteQueryRunner.ts#L1935-L1956","documentation":"SQLite has no native table-comment support, so AbstractSqliteQueryRunner.changeTableComment() unconditionally throws TypeORMError on call. There is no workaround on this driver.","triggerScenarios":"Calling queryRunner.changeTableComment(table, comment) on a SQLite DataSource, or an entity declaring a comment that TypeORM tries to apply during sync/migration.","commonSituations":"Entities with `@Entity({ comment: '...' })` synced against SQLite; cross-driver schema code that sets comments; code ported from Postgres/MySQL.","solutions":["Remove `comment` from entities used with SQLite.","Branch schema setup on driver type — only set comments for drivers that support them.","Store documentation elsewhere (a metadata table, code comments) if you need it on SQLite."],"exampleFix":"// before\n@Entity({ comment: 'Application users' })\nclass User {}\n\n// after (for SQLite-targeted entities)\n@Entity()\nclass User {}","handlingStrategy":"type-guard","validationCode":"function supportsTableComments(ds: DataSource): boolean {\n  const t = ds.options.type;\n  return t !== 'sqlite' && t !== 'sqlite-pooled' && t !== 'better-sqlite3';\n}\n\nif (supportsTableComments(dataSource)) {\n  await queryRunner.changeTableComment(table, 'users');\n}","typeGuard":"const driverSupportsTableComments = (ds: DataSource): boolean =>\n  ds.options.type !== 'sqlite' &&\n  ds.options.type !== 'sqlite-pooled' &&\n  ds.options.type !== 'better-sqlite3';","tryCatchPattern":null,"preventionTips":["Omit `comment` from entities used with SQLite.","Branch comment-setting logic on driver type.","Keep driver-specific schema features behind capability checks."],"tags":["database","sqlite"],"backgroundTag":null,"analyzedSha":"5ac6606e81f67bb9534255570cd4e86fd8101eee","analyzedAt":"2026-08-12T05:26:35.080Z","schemaVersion":2},"datasetVersion":"2026-08-12T13:17:24.610Z"}