PHP 大会日本 2024

Pdo\Firebird 类

(PHP 8 >= 8.4.0)

简介

一个表示使用 Firebird PDO 驱动程序的连接的 PDO 子类。

类概要

class Pdo\Firebird extends PDO {
/* 继承的常量 */
public const int PDO::PARAM_NULL;
public const int PDO::PARAM_BOOL = 5;
public const int PDO::PARAM_INT = 1;
public const int PDO::PARAM_STR = 2;
public const int PDO::PARAM_LOB = 3;
public const int PDO::PARAM_STMT = 4;
public const int PDO::PARAM_STR_NATL;
public const int PDO::PARAM_STR_CHAR;
public const int PDO::PARAM_EVT_FREE;
public const int PDO::FETCH_DEFAULT;
public const int PDO::FETCH_LAZY;
public const int PDO::FETCH_ASSOC;
public const int PDO::FETCH_NUM;
public const int PDO::FETCH_BOTH;
public const int PDO::FETCH_OBJ;
public const int PDO::FETCH_BOUND;
public const int PDO::FETCH_COLUMN;
public const int PDO::FETCH_CLASS;
public const int PDO::FETCH_INTO;
public const int PDO::FETCH_FUNC;
public const int PDO::FETCH_GROUP;
public const int PDO::FETCH_UNIQUE;
public const int PDO::FETCH_KEY_PAIR;
public const int PDO::FETCH_NAMED;
public const int PDO::ATTR_PREFETCH;
public const int PDO::ATTR_TIMEOUT;
public const int PDO::ATTR_ERRMODE;
public const int PDO::ATTR_CASE;
public const int PDO::ATTR_CURSOR;
public const int PDO::ERRMODE_SILENT;
public const int PDO::CASE_NATURAL;
public const int PDO::CASE_LOWER;
public const int PDO::CASE_UPPER;
public const int PDO::NULL_NATURAL;
public const int PDO::NULL_TO_STRING;
public const string PDO::ERR_NONE;
public const int PDO::FETCH_ORI_NEXT;
public const int PDO::FETCH_ORI_LAST;
public const int PDO::FETCH_ORI_ABS;
public const int PDO::FETCH_ORI_REL;
public const int PDO::CURSOR_FWDONLY;
public const int PDO::CURSOR_SCROLL;
/* 常量 */
public const int ATTR_DATE_FORMAT;
public const int ATTR_TIME_FORMAT;
public const int READ_COMMITTED;
public const int REPEATABLE_READ;
public const int SERIALIZABLE;
/* 方法 */
public static getApiVersion(): int
/* 继承的方法 */
public PDO::__construct(
    string $dsn,
    ?string $username = null,
    #[\SensitiveParameter] ?string $password = null,
    ?array $options = null
)
public PDO::commit(): bool
public static PDO::connect(
    string $dsn,
    ?string $username = null,
    #[\SensitiveParameter] ?string $password = null,
    ?array $options = null
): static
public PDO::exec(string $statement): int|false
public PDO::getAttribute(int $attribute): mixed
public PDO::prepare(string $query, array $options = []): PDOStatement|false
public PDO::query(字符串 $query, ?整数 $fetchMode = null): PDOStatement|false
public PDO::query(字符串 $query, ?整数 $fetchMode = PDO::FETCH_COLUMN, 整数 $colno): PDOStatement|false
public PDO::query(
    字符串 $query,
    ?整数 $fetchMode = PDO::FETCH_CLASS,
    字符串 $classname,
    数组 $constructorArgs
): PDOStatement|false
public PDO::query(字符串 $query, ?整数 $fetchMode = PDO::FETCH_INTO, 对象 $object): PDOStatement|false
public PDO::quote(字符串 $string, 整数 $type = PDO::PARAM_STR): 字符串|false
public PDO::setAttribute(整数 $attribute, 混合类型 $value): 布尔值
}

预定义常量

Pdo\Firebird::ATTR_DATE_FORMAT
设置日期格式。
Pdo\Firebird::ATTR_TIME_FORMAT
设置时间格式。
Pdo\Firebird::ATTR_TIMESTAMP_FORMAT
设置时间戳格式。
Pdo\Firebird::TRANSACTION_ISOLATION_LEVEL
属性用于设置事务隔离级别。这可以是以下之一:Pdo\Firebird::READ_COMMITTEDPdo\Firebird::REPEATABLE_READPdo\Firebird::SERIALIZABLE
Pdo\Firebird::READ_COMMITTED
表示ANSI事务隔离级别为读已提交。这是默认行为。
Pdo\Firebird::REPEATABLE_READ
表示ANSI事务隔离级别为可重复读。这对应于 Firebird 的“快照”隔离级别。
Pdo\Firebird::SERIALIZABLE
表示ANSI事务隔离级别为可序列化。这对应于 Firebird 的“快照表稳定性”隔离级别。
Pdo\Firebird::WRITABLE_TRANSACTION
布尔属性用于在READ ONLYREAD WRITE之间切换事务访问模式。默认情况下,它是true,表示READ WRITE

目录

添加注释

用户贡献的注释

此页面没有用户贡献的注释。
To Top