Commit df2f3ba7 by Pfuhl, Thomas

bugfix: hardcoded DB replaced by env variable

parent f7d97b7c
......@@ -121,7 +121,7 @@ function getAllForeignKeys() {
FROM
INFORMATION_SCHEMA.KEY_COLUMN_USAGE
WHERE
TABLE_SCHEMA = '" . "projektmetadaten" . "' AND REFERENCED_TABLE_NAME != 'DATABASECHANGELOG' AND REFERENCED_TABLE_NAME != 'DATABASECHANGELOGLOCK'";
TABLE_SCHEMA = '" . $env["DB_DATABASE"] . "' AND REFERENCED_TABLE_NAME != 'DATABASECHANGELOG' AND REFERENCED_TABLE_NAME != 'DATABASECHANGELOGLOCK'";
$pdo = new PDO('mysql:host=' . $env["DB_HOST"] . ';' . 'dbname=' . $env["DB_DATABASE"], $env["DB_USERNAME"], $env["DB_PASSWORD"]);
$response = $pdo->query($sql);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment