{"record":{"id":"3b5d52e2d50a8813","repo":"nocodb/nocodb","slug":"schemalist-not-supported-for-sqlite","errorCode":null,"errorMessage":"SchemaList : Not supported for sqlite","messagePattern":"SchemaList : Not supported for sqlite","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"warning","filePath":"packages/nocodb/src/db/sql-client/lib/sqlite/SqliteClient.ts","lineNumber":333,"sourceCode":"        }\n      }\n\n      //result.data.list = response;\n    } catch (e) {\n      log.ppe(e, _func);\n      throw e;\n    }\n\n    log.api(`${_func}: result`, result);\n    return result;\n  }\n\n  async schemaList(args: any = {}) {\n    const _func = this.schemaList.name;\n    const result = new Result();\n    log.api(`${_func}:args:`, args);\n\n    throw new Error('SchemaList : Not supported for sqlite');\n\n    log.api(`${_func}: result`, result);\n    return result;\n  }\n\n  /**\n   *\n   * @param {Object} - args - Input arguments\n   * @param {Object} - args.tn -\n   * @returns {Object[]} - columns\n   * @property {String} - columns[].tn\n   * @property {String} - columns[].cn\n   * @property {String} - columns[].dt\n   * @property {String} - columns[].dtx\n   * @property {String} - columns[].np\n   * @property {String} - columns[].ns -\n   * @property {String} - columns[].clen -\n   * @property {String} - columns[].dp -","sourceCodeStart":315,"sourceCodeEnd":351,"githubUrl":"https://github.com/nocodb/nocodb/blob/d3caaf4e890acf64bd49b788cf6dc32b7644c895/packages/nocodb/src/db/sql-client/lib/sqlite/SqliteClient.ts#L315-L351","documentation":"Thrown unconditionally by SqliteClient.schemaList. SQLite is a single-database, schema-less engine — it has no concept of separate schemas within a database file. The method is implemented only to satisfy the shared SqlClient interface contract; calling it always throws. The code after the throw (log + return result) is dead — unreachable.","triggerScenarios":"Any code path that calls schemaList() on a SqliteClient instance: schema introspection UI, migration tooling, or sync logic that iterates databases and calls schemaList uniformly across client types without checking the dialect.","commonSituations":"A workspace configured with SQLite that triggers a generic schema-listing flow designed for PostgreSQL/MySQL; tooling that does not short-circuit SQLite before calling schemaList.","solutions":["Guard callers: check the client type and skip schemaList for sqlite3 before invoking it.","If schema enumeration is needed, treat SQLite as having a single implicit schema rather than calling this method."],"exampleFix":"// before\nconst schemas = await sqlClient.schemaList();\n// after\nconst schemas = sqlClient.clientType === 'sqlite3' ? [{ name: 'main' }] : await sqlClient.schemaList();","handlingStrategy":"validation","validationCode":"async function safeSchemaList(sqlClient: any) {\n  if (sqlClient.clientType === 'sqlite3') {\n    return [{ schema_name: 'main' }]; // SQLite has a single implicit schema\n  }\n  return sqlClient.schemaList();\n}","typeGuard":"function isSqliteClient(sqlClient: any): boolean {\n  return sqlClient?.clientType === 'sqlite3';\n}","tryCatchPattern":"try {\n  const schemas = await sqlClient.schemaList();\n} catch (e) {\n  if (e.message === 'SchemaList : Not supported for sqlite') {\n    return [{ schema_name: 'main' }];\n  }\n  throw e;\n}","preventionTips":["Check clientType === 'sqlite3' before calling schemaList and short-circuit with a single-schema result.","Do not route SQLite connections through generic schema-enumeration flows designed for PostgreSQL/MySQL.","Document that SQLite workspaces always use the implicit 'main' schema."],"tags":["schema","sqlite","unsupported","introspection"],"backgroundTag":null,"analyzedSha":"d3caaf4e890acf64bd49b788cf6dc32b7644c895","analyzedAt":"2026-08-12T13:07:32.092Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}