aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/connection_adapters/db2_adapter.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/lib/active_record/connection_adapters/db2_adapter.rb')
-rw-r--r--activerecord/lib/active_record/connection_adapters/db2_adapter.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/activerecord/lib/active_record/connection_adapters/db2_adapter.rb b/activerecord/lib/active_record/connection_adapters/db2_adapter.rb
index 7e3627261a..515444a21e 100644
--- a/activerecord/lib/active_record/connection_adapters/db2_adapter.rb
+++ b/activerecord/lib/active_record/connection_adapters/db2_adapter.rb
@@ -219,4 +219,12 @@ begin
end
rescue LoadError
# DB2 driver is unavailable.
+ module ActiveRecord # :nodoc:
+ class Base # :nodoc:
+ def self.db2_connection(config) # :nodoc:
+ # Set up a reasonable error message
+ raise LoadError, "DB2 Libraries could not be loaded."
+ end
+ end
+ end
end