mirror of
https://github.com/vrana/adminer.git
synced 2025-08-13 10:04:07 +02:00
Driver specific trigger options
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@1478 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
@@ -397,7 +397,7 @@ WHERE tc.constraint_type = 'FOREIGN KEY' AND tc.table_name = " . $connection->qu
|
||||
|
||||
function trigger($name) {
|
||||
global $connection;
|
||||
$result = $connection->query('SELECT trigger_name AS "Trigger", condition_timing AS "Timing", event_manipulation AS "Event", action_statement AS "Statement" FROM information_schema.triggers WHERE event_object_table = ' . $connection->quote($_GET["trigger"]) . ' AND trigger_name = ' . $connection->quote($name));
|
||||
$result = $connection->query('SELECT trigger_name AS "Trigger", condition_timing AS "Timing", event_manipulation AS "Event", action_statement AS "Statement" FROM information_schema.triggers WHERE event_object_table = ' . $connection->quote($_GET["trigger"]) . ' AND trigger_name = ' . $connection->quote($name)); //! detect Type
|
||||
return $result->fetch_assoc();
|
||||
}
|
||||
|
||||
@@ -411,6 +411,13 @@ WHERE tc.constraint_type = 'FOREIGN KEY' AND tc.table_name = " . $connection->qu
|
||||
return $return;
|
||||
}
|
||||
|
||||
function trigger_options() {
|
||||
return array(
|
||||
"Timing" => array("BEFORE", "AFTER"),
|
||||
"Type" => array("FOR EACH STATEMENT", "FOR EACH ROW"),
|
||||
);
|
||||
}
|
||||
|
||||
function explain($connection, $query) {
|
||||
return $connection->query("EXPLAIN $query");
|
||||
}
|
||||
|
Reference in New Issue
Block a user