diff --git a/Database/SQLite3.hs b/Database/SQLite3.hs
--- a/Database/SQLite3.hs
+++ b/Database/SQLite3.hs
@@ -215,7 +215,7 @@
         -- ^ Indicates what action produced this error,
         --   e.g. @exec \"SELECT * FROM foo\"@
     }
-    deriving Typeable
+    deriving (Eq, Typeable)
 
 -- NB: SQLError is lazy in 'sqlErrorDetails' and 'sqlErrorContext',
 -- to defer message construction in the case where a user catches and
@@ -391,11 +391,11 @@
 -- If the query string contains no SQL statements, this 'fail's.
 prepare :: Database -> Text -> IO Statement
 prepare db sql = prepareUtf8 db (toUtf8 sql)
-        
+
 -- | <http://www.sqlite.org/c3ref/prepare.html>
 --
 -- It can help to avoid redundant Utf8 to Text conversion if you already
--- have Utf8 
+-- have Utf8
 --
 -- If the query string contains no SQL statements, this 'fail's.
 prepareUtf8 :: Database -> Utf8 -> IO Statement
@@ -617,7 +617,7 @@
 
 -- |
 -- This avoids extra API calls using the list of column types.
--- If passed types do not correspond to the actual types, the values will be 
+-- If passed types do not correspond to the actual types, the values will be
 -- converted according to the rules at <http://www.sqlite.org/c3ref/column_blob.html>.
 -- If the list contains more items that number of columns, the result is undefined.
 typedColumns :: Statement -> [Maybe ColumnType] -> IO [SQLData]
diff --git a/changelog b/changelog
--- a/changelog
+++ b/changelog
@@ -1,3 +1,6 @@
+v2.3.16
+	* Add an Eq instance for SQLError
+
 v2.3.15
 	* Add support for the online backup API
 
diff --git a/direct-sqlite.cabal b/direct-sqlite.cabal
--- a/direct-sqlite.cabal
+++ b/direct-sqlite.cabal
@@ -1,5 +1,5 @@
 name: direct-sqlite
-version: 2.3.15
+version: 2.3.16
 build-type: Simple
 license: BSD3
 license-file: LICENSE
