We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
getDatabasePlatform
1 parent 04a9e9d commit 1e3ec9aCopy full SHA for 1e3ec9a
src/Crate/DBAL/Driver/PDOCrate/Driver.php
@@ -78,7 +78,14 @@ private function constructPdoDsn(array $params): string
78
*/
79
public function getDatabasePlatform(): AbstractPlatform
80
{
81
- return new CratePlatform4();
+ // FIXME: Chicken egg problem: No connection information here.
82
+ // Is this meant to "activate" the right platform *after* a server
83
+ // inquiry at all? Isn't it more likely it is NOT meant to work this way?
84
+ // Let's investigate how the other vendors are doing it.
85
+ $conn = $this->connect();
86
+ $version = $conn->getServerVersion();
87
+ $platform = $this->createDatabasePlatformForVersion($version);
88
+ return $platform;
89
}
90
91
/**
0 commit comments