Bug 12478: working on authority results
[koha-ffzg.git] / Koha / Database.pm
index 014554f..ff289c2 100644 (file)
@@ -41,6 +41,8 @@ use vars qw($database);
 
 __PACKAGE__->mk_accessors(qw( ));
 
+our $schema; # the schema is a singleton
+
 # _new_schema
 # Internal helper function (not a method!). This creates a new
 # database connection from the data given in the current context, and
@@ -77,7 +79,9 @@ sub _new_schema {
             password => $db_passwd,
             %encoding_attr,
             RaiseError => $ENV{DEBUG} ? 1 : 0,
+            PrintError => 1,
             unsafe => 1,
+            quote_names => 1,
             on_connect_do => [
                 $encoding_query || (),
                 $tz_query || (),
@@ -108,8 +112,7 @@ creates one, and connects to the database.
 
 This database handle is cached for future use: if you call
 C<$database-E<gt>schema> twice, you will get the same handle both
-times. If you need a second database handle, use C<&new_schema> and
-possibly C<&set_schema>.
+times. If you need a second database handle, use C<&new_schema>.
 
 =cut