[Bps-public-commit] dbix-searchbuilder branch, master, updated. 1.65_02

Alex Vandiver alexmv at bestpractical.com
Tue Aug 19 18:09:21 EDT 2014


The branch, master has been updated
       via  c55e2a93ac5ebc64189e8b8fb841d945c66172d2 (commit)
       via  1573988f8bbfa3171fdb7cf26e86cf5d14287f34 (commit)
      from  8e843ec1b0592b24c51667ce407c325f7974e199 (commit)

Summary of changes:
 Changes                          | 10 ++++++++++
 META.yml                         |  2 +-
 lib/DBIx/SearchBuilder.pm        |  9 +++++----
 lib/DBIx/SearchBuilder/Handle.pm |  2 +-
 4 files changed, 17 insertions(+), 6 deletions(-)

- Log -----------------------------------------------------------------
commit 1573988f8bbfa3171fdb7cf26e86cf5d14287f34
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Tue Aug 19 17:55:07 2014 -0400

    Return column names from ->Fields case-sensitively
    
    As some databases are case-sensitive, lower-casing all column names
    loses information.  Return the columns in the case that the database
    listed them, for consistency.

diff --git a/lib/DBIx/SearchBuilder.pm b/lib/DBIx/SearchBuilder.pm
index ad9db1b..0d23d9b 100755
--- a/lib/DBIx/SearchBuilder.pm
+++ b/lib/DBIx/SearchBuilder.pm
@@ -1785,9 +1785,8 @@ sub AdditionalColumn {
 
 =head2 Fields TABLE
 
-Return a list of fields in TABLE, lowercased.
-
-TODO: Why are they lowercased?
+Return a list of fields in TABLE.  These fields are in the case
+presented by the database, which may be case-sensitive.
 
 =cut
 
@@ -1801,6 +1800,8 @@ sub Fields {
 Returns true if TABLE has field FIELD.
 Return false otherwise
 
+Note: Both TABLE and FIELD are case-sensitive (See: L</Fields>)
+
 =cut
 
 sub HasField {
diff --git a/lib/DBIx/SearchBuilder/Handle.pm b/lib/DBIx/SearchBuilder/Handle.pm
index 35b0b68..6ed2cc8 100755
--- a/lib/DBIx/SearchBuilder/Handle.pm
+++ b/lib/DBIx/SearchBuilder/Handle.pm
@@ -1433,7 +1433,7 @@ sub Fields {
             or return ();
         my $info = $sth->fetchall_arrayref({});
         foreach my $e ( @$info ) {
-            push @{ $FIELDS_IN_TABLE{ $table } }, lc $e->{'COLUMN_NAME'};
+            push @{ $FIELDS_IN_TABLE{ $table } }, $e->{'COLUMN_NAME'};
         }
     }
 

commit c55e2a93ac5ebc64189e8b8fb841d945c66172d2
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Tue Aug 19 18:09:08 2014 -0400

    Version 1.65_02 releng

diff --git a/Changes b/Changes
index b582a53..f1cb270 100644
--- a/Changes
+++ b/Changes
@@ -1,5 +1,15 @@
 Revision history for Perl extension DBIx::SearchBuilder.
 
+1.65_02
+ - Stop unilaterally disabling the "UTF8" flag before executing queries
+ - Make ->Fields case-sensitive in the column names it returns, as well
+   as in the table name it takes.
+
+1.65_01
+ - Make ->Fields only lookup information on the table requested, not all
+   fields, for performance.  It also is now case-sensitive in table name.
+ - Omit calls to ->Fields entirely for PostgreSQL 9.1 and above
+
 1.65 2013-07-03
  - Bug fix for DateTimeInterval extraction on Pg
 
diff --git a/META.yml b/META.yml
index 555f116..8fff554 100644
--- a/META.yml
+++ b/META.yml
@@ -34,4 +34,4 @@ requires:
   Want: 0
 resources:
   license: http://dev.perl.org/licenses/
-version: 1.65_01
+version: 1.65_02
diff --git a/lib/DBIx/SearchBuilder.pm b/lib/DBIx/SearchBuilder.pm
index 0d23d9b..7f9d1e4 100755
--- a/lib/DBIx/SearchBuilder.pm
+++ b/lib/DBIx/SearchBuilder.pm
@@ -4,7 +4,7 @@ package DBIx::SearchBuilder;
 use strict;
 use warnings;
 
-our $VERSION = "1.65_01";
+our $VERSION = "1.65_02";
 
 use Clone qw();
 use Encode qw();

-----------------------------------------------------------------------


More information about the Bps-public-commit mailing list