From 0d100b57dcffe54ec7f46d8f577a4c26fcf34202 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Fri, 26 Dec 2008 14:23:38 +0000 Subject: - Patch #332002 by Crell et al: MergeQuery should refuse to execute if there are no key fields. With tests. --- includes/database/database.inc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'includes/database/database.inc') diff --git a/includes/database/database.inc b/includes/database/database.inc index eecb8f88c..043515548 100644 --- a/includes/database/database.inc +++ b/includes/database/database.inc @@ -1169,6 +1169,14 @@ abstract class Database { */ class TransactionsNotSupportedException extends PDOException { } +/** + * Exception thrown for merge queries that do not make semantic sense. + * + * There are many ways that a merge query could be malformed. They should all + * throw this exception and set an appropriately descriptive message. + */ +class InvalidMergeQueryException extends Exception {} + /** * A wrapper class for creating and managing database transactions. * -- cgit v1.2.3