UNPKG

typeorm

Version:

Data-Mapper ORM for TypeScript and ES2023+. Supports MySQL/MariaDB, PostgreSQL, MS SQL Server, Oracle, SAP HANA, SQLite, MongoDB databases.

38 lines (37 loc) 1.3 kB
import type { ObjectLiteral } from "../../common/ObjectLiteral"; import { AbstractSqliteQueryRunner } from "../sqlite-abstract/AbstractSqliteQueryRunner"; import type { BetterSqlite3Driver } from "./BetterSqlite3Driver"; /** * Runs queries on a single sqlite database connection. * * Does not support compose primary keys with autoincrement field. * todo: need to throw exception for this case. */ export declare class BetterSqlite3QueryRunner extends AbstractSqliteQueryRunner { /** * Database driver used by connection. */ driver: BetterSqlite3Driver; constructor(driver: BetterSqlite3Driver); private cacheSize; private stmtCache; private getStmt; /** * Called before migrations are run. */ beforeMigration(): Promise<void>; /** * Called after migrations are run. */ afterMigration(): Promise<void>; /** * Executes a given SQL query. * * @param query * @param parameters * @param useStructuredResult */ query(query: string, parameters?: any[] | ObjectLiteral, useStructuredResult?: boolean): Promise<any>; protected loadTableRecords(tablePath: string, tableOrIndex: "table" | "index"): Promise<any>; protected loadPragmaRecords(tablePath: string, pragma: string): Promise<any>; }