Skip to content

Connection::getCurrentSchema #7

@tyrsson

Description

@tyrsson

Package Version

0.0.1

Php Version

8.2

Database Engine

SQLite

Basic Information

Connection::getCurrentSchema() is return typed for string|bool. The issue is that the body of the method was changed during migration. This method in laminas-db 2.2x simply returned 'main'. Somehow the method body was refactored so that it was running a PRAGMA query for database_list. The issue there is depending on how the connection is setup determines what if anything will be returned.

I will be returning the return value to 'main' as testing indicates that will fix the issue for the time being. We can look into improving it in 0.0.2

See this line for reference:
https://github.com/laminas/laminas-db/blob/c8c4c6a4d9b21764399d20fc157b4d1a21d0ce37/src/Adapter/Driver/Pdo/Connection.php#L114

Steps to Reproduce

N/A

Expected Behavior

N/A

Actual behavior?

See above

Additional Info

No response

Metadata

Metadata

Assignees

Type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions