Hello community,

here is the log from the commit of package perl-DBD-SQLite for openSUSE:Factory 
checked in at 2013-07-31 17:24:24
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-DBD-SQLite (Old)
 and      /work/SRC/openSUSE:Factory/.perl-DBD-SQLite.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-DBD-SQLite"

Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-DBD-SQLite/perl-DBD-SQLite.changes  
2013-07-27 15:50:05.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-DBD-SQLite.new/perl-DBD-SQLite.changes     
2013-07-31 17:24:26.000000000 +0200
@@ -1,0 +2,7 @@
+Sun Jul 28 20:18:35 UTC 2013 - co...@suse.com
+
+- updated to 1.40
+    - NetBSD also doesn't like the _XOPEN_SOURCE hack (ISHIGAKI)
+    - Resolved #86080: PATCH: statistics_info support (DDICK)
+
+-------------------------------------------------------------------

Old:
----
  DBD-SQLite-1.39.tar.gz

New:
----
  DBD-SQLite-1.40.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-DBD-SQLite.spec ++++++
--- /var/tmp/diff_new_pack.ZuPc7s/_old  2013-07-31 17:24:27.000000000 +0200
+++ /var/tmp/diff_new_pack.ZuPc7s/_new  2013-07-31 17:24:27.000000000 +0200
@@ -21,7 +21,7 @@
 Summary:        Self-contained RDBMS in a DBI Driver
 License:        GPL-1.0+ or Artistic-1.0
 Group:          Development/Libraries/Perl
-Version:        1.39
+Version:        1.40
 Release:        0
 Url:            http://search.cpan.org/dist/DBD-SQLite/
 Source:         
http://www.cpan.org/authors/id/I/IS/ISHIGAKI/%{cpan_name}-%{version}.tar.gz

++++++ DBD-SQLite-1.39.tar.gz -> DBD-SQLite-1.40.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/DBD-SQLite-1.39/Changes new/DBD-SQLite-1.40/Changes
--- old/DBD-SQLite-1.39/Changes 2013-06-09 17:03:58.000000000 +0200
+++ new/DBD-SQLite-1.40/Changes 2013-07-28 07:29:31.000000000 +0200
@@ -1,5 +1,9 @@
 Changes for Perl extension DBD-SQLite
 
+1.40 Sun 28 Jul 2013
+    - NetBSD also doesn't like the _XOPEN_SOURCE hack (ISHIGAKI)
+    - Resolved #86080: PATCH: statistics_info support (DDICK)
+
 1.39 Fri 31 May 2013
     - Production release, no changes from 1.38_05
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/DBD-SQLite-1.39/META.json 
new/DBD-SQLite-1.40/META.json
--- old/DBD-SQLite-1.39/META.json       2013-06-09 17:10:07.000000000 +0200
+++ new/DBD-SQLite-1.40/META.json       2013-07-28 07:31:22.000000000 +0200
@@ -54,5 +54,5 @@
       },
       "x_MailingList" : 
"http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbd-sqlite";
    },
-   "version" : "1.39"
+   "version" : "1.40"
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/DBD-SQLite-1.39/META.yml new/DBD-SQLite-1.40/META.yml
--- old/DBD-SQLite-1.39/META.yml        2013-06-09 17:10:06.000000000 +0200
+++ new/DBD-SQLite-1.40/META.yml        2013-07-28 07:31:22.000000000 +0200
@@ -29,4 +29,4 @@
   bugtracker: http://rt.cpan.org/Public/Dist/Display.html?Name=DBD-SQLite
   license: http://dev.perl.org/licenses/
   repository: https://github.com/DBD-SQLite/DBD-SQLite
-version: 1.39
+version: 1.40
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/DBD-SQLite-1.39/Makefile.PL 
new/DBD-SQLite-1.40/Makefile.PL
--- old/DBD-SQLite-1.39/Makefile.PL     2013-05-31 06:30:29.000000000 +0200
+++ new/DBD-SQLite-1.40/Makefile.PL     2013-07-28 07:29:31.000000000 +0200
@@ -248,7 +248,7 @@
 if ($^O eq 'aix') {
        push @CC_DEFINE, '-DSQLITE_DISABLE_DIRSYNC';
 }
-if ($^O =~ /bsd/i && $^O ne 'openbsd') {
+if ($^O =~ /bsd/i && $^O !~ /(?:open|net)bsd/) {
        push @CC_DEFINE, '-D_XOPEN_SOURCE';
 }
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/DBD-SQLite-1.39/lib/DBD/SQLite.pm 
new/DBD-SQLite-1.40/lib/DBD/SQLite.pm
--- old/DBD-SQLite-1.39/lib/DBD/SQLite.pm       2013-06-09 17:04:08.000000000 
+0200
+++ new/DBD-SQLite-1.40/lib/DBD/SQLite.pm       2013-07-28 07:29:31.000000000 
+0200
@@ -5,7 +5,7 @@
 use DBI   1.57 ();
 use DynaLoader ();
 
-our $VERSION = '1.39';
+our $VERSION = '1.40';
 our @ISA     = 'DynaLoader';
 
 # sqlite_version cache (set in the XS bootstrap)
@@ -613,6 +613,90 @@
     }) or return $dbh->DBI::set_err(
         $sponge_dbh->err,
         $sponge_dbh->errstr,
+    );
+    return $sponge_sth;
+}
+
+my @STATISTICS_INFO_ODBC = (
+  'TABLE_CAT',        # The catalog identifier.
+  'TABLE_SCHEM',      # The schema identifier.
+  'TABLE_NAME',       # The table identifier.
+  'NON_UNIQUE',       # Unique index indicator.
+  'INDEX_QUALIFIER',  # Index qualifier identifier.
+  'INDEX_NAME',       # The index identifier.
+  'TYPE',             # The type of information being returned.
+  'ORDINAL_POSITION', # Column sequence number (starting with 1).
+  'COLUMN_NAME',      # The column identifier.
+  'ASC_OR_DESC',      # Column sort sequence.
+  'CARDINALITY',      # Cardinality of the table or index.
+  'PAGES',            # Number of storage pages used by this table or index.
+  'FILTER_CONDITION', # The index filter condition as a string.
+);
+
+sub statistics_info {
+    my ($dbh, $catalog, $schema, $table, $unique_only, $quick) = @_;
+
+    my $databases = $dbh->selectall_arrayref("PRAGMA database_list", {Slice => 
{}});
+
+    my @statistics_info;
+    for my $database (@$databases) {
+        my $dbname = $database->{name};
+        next if defined $schema && $schema ne '%' && $schema ne $dbname;
+
+        my $quoted_dbname = $dbh->quote_identifier($dbname);
+        my $master_table =
+            ($dbname eq 'main') ? 'sqlite_master' :
+            ($dbname eq 'temp') ? 'sqlite_temp_master' :
+            $quoted_dbname.'.sqlite_master';
+
+        my $tables = $dbh->selectall_arrayref("SELECT name FROM $master_table 
WHERE type = ?", undef, "table");
+        for my $table_ref (@$tables) {
+            my $tbname = $table_ref->[0];
+            next if defined $table && $table ne '%' && $table ne $tbname;
+
+            my $quoted_tbname = $dbh->quote_identifier($tbname);
+            my $sth = $dbh->prepare("PRAGMA 
$quoted_dbname.index_list($quoted_tbname)");
+            $sth->execute;
+            while(my $row = $sth->fetchrow_hashref) {
+
+                next if defined $unique_only && $unique_only && $row->{unique};
+                my $quoted_idx = $dbh->quote_identifier($row->{name});
+                for my $db (@$databases) {
+                    my $quoted_db = $dbh->quote_identifier($db->{name});
+                    my $i_sth = $dbh->prepare("PRAGMA 
$quoted_db.index_info($quoted_idx)");
+                    $i_sth->execute;
+                    my $cols = {};
+                    while(my $info = $i_sth->fetchrow_hashref) {
+                        push @statistics_info, {
+                            TABLE_CAT   => undef,
+                            TABLE_SCHEM => $db->{name},
+                            TABLE_NAME  => $tbname,
+                            NON_UNIQUE    => $row->{unique} ? 0 : 1, 
+                            INDEX_QUALIFIER => undef,
+                            INDEX_NAME      => $row->{name},
+                            TYPE            => 'btree', # see 
http://www.sqlite.org/version3.html esp. "Traditional B-trees are still used 
for indices"
+                            ORDINAL_POSITION => $info->{seqno} + 1,
+                            COLUMN_NAME      => $info->{name},
+                            ASC_OR_DESC      => undef,
+                            CARDINALITY      => undef,
+                            PAGES            => undef,
+                            FILTER_CONDITION => undef,
+                       };
+                    }
+                }
+            }
+        }
+    }
+
+    my $sponge_dbh = DBI->connect("DBI:Sponge:", "", "")
+        or return $dbh->DBI::set_err($DBI::err, "DBI::Sponge: $DBI::errstr");
+    my $sponge_sth = $sponge_dbh->prepare("statistics_info", {
+        NAME          => \@STATISTICS_INFO_ODBC,
+        rows          => [ map { [@{$_}{@STATISTICS_INFO_ODBC} ] } 
@statistics_info ],
+        NUM_OF_FIELDS => scalar(@STATISTICS_INFO_ODBC),
+    }) or return $dbh->DBI::set_err(
+        $sponge_dbh->err,
+        $sponge_dbh->errstr,
     );
     return $sponge_sth;
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/DBD-SQLite-1.39/t/lib/Test.pm 
new/DBD-SQLite-1.40/t/lib/Test.pm
--- old/DBD-SQLite-1.39/t/lib/Test.pm   2013-06-09 17:04:19.000000000 +0200
+++ new/DBD-SQLite-1.40/t/lib/Test.pm   2013-07-28 07:29:31.000000000 +0200
@@ -7,7 +7,7 @@
 use File::Spec ();
 use Test::More ();
 
-our $VERSION = '1.39';
+our $VERSION = '1.40';
 our @ISA     = 'Exporter';
 our @EXPORT  = qw/connect_ok dies dbfile @CALL_FUNCS/;
 our @CALL_FUNCS;

-- 
To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org
For additional commands, e-mail: opensuse-commit+h...@opensuse.org

Reply via email to