Skip to content

Schema not loading with PDO::ATTR_STRINGIFY_FETCHES => true #314

@Tigrov

Description

@Tigrov
$dsn = (new Dsn('pgsql', '127.0.0.1'))->asString();
$pdoDriver = new Driver($dsn, 'postgres', '', [\PDO::ATTR_STRINGIFY_FETCHES => true]);
$schemaCache = new SchemaCache(new FileCache(__DIR__ . '/runtime/cache'));
$db = new Connection($pdoDriver, $schemaCache);
$schema = $db->getSchema();
$tableSchema = $schema->getTableSchema('table_name', true);

The result is
TypeError: Yiisoft\Db\Schema\AbstractColumnSchema::allowNull(): Argument #1 ($value) must be of type bool, string given, called in ...\db-pgsql\src\Schema.php on line 775

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions