Skip to Content
Skip to Content
ClassesSQLite3Database

SQLite3Database


Methods

transaction

Creates a transaction function.

:transaction(callback: ((A...) -> R...), kind: type TransactionKind = "deferred" | "immediate" | "exclusive"TransactionKindtype TransactionKind = "deferred" | "immediate" | "exclusive"?): ((A...) -> R...)

Parameters

  • callback: ((A...) -> R...) - The callback to run inside the transaction.
  • kind: TransactionKind? - The transaction mode to use.

Throws

  • Luau Error

query

:query(query: string | buffer): SQLite3Statement

Parameters

  • query: string | buffer - The query to prepare.

Throws

  • SQLite3 Error
  • Memory Error

exec

:exec(query: string | buffer, args: export type SQLite3Values = { [string]: number | string | buffer }SQLite3Valuesexport type SQLite3Values = { [string]: number | string | buffer }?): export type SQLite3Result = { last_insert_row_id: number, changes: number, }SQLite3Resultexport type SQLite3Result = { last_insert_row_id: number, changes: number, }

Parameters

  • query: string | buffer - The query to execute.
  • args: SQLite3Values? - The arguments to bind to the query.

Throws

  • SQLite3 Error
  • Memory Error

close

:close(): ()
Last updated on