[Rt-commit] [svn] r1629 - in
DBIx-SearchBuilder/branches/1.20-SYBASE: . SearchBuilder
SearchBuilder/Handle
jesse at pallas.eruditorum.org
jesse at pallas.eruditorum.org
Mon Oct 4 16:09:57 EDT 2004
Author: jesse
Date: Mon Oct 4 16:09:57 2004
New Revision: 1629
Modified:
DBIx-SearchBuilder/branches/1.20-SYBASE/ (props changed)
DBIx-SearchBuilder/branches/1.20-SYBASE/META.yml
DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder.pm
DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle.pm
DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle/Sybase.pm
Log:
r10480 at tinbook: jesse | 2004-10-04T20:08:15.486436Z
Misc sybase updates
Modified: DBIx-SearchBuilder/branches/1.20-SYBASE/META.yml
==============================================================================
--- DBIx-SearchBuilder/branches/1.20-SYBASE/META.yml (original)
+++ DBIx-SearchBuilder/branches/1.20-SYBASE/META.yml Mon Oct 4 16:09:57 2004
@@ -1,5 +1,5 @@
name: DBIx-SearchBuilder
-version: 1.11
+version: 1.12_01
license: perl
distribution_type: module
build_requires:
@@ -12,4 +12,4 @@
no_index:
directory:
- inc
-generated_by: Module::Install version 0.35
+generated_by: Module::Install version 0.36
Modified: DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder.pm
==============================================================================
--- DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder.pm (original)
+++ DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder.pm Mon Oct 4 16:09:57 2004
@@ -1222,8 +1222,10 @@
sub RowsPerPage {
my $self = shift;
- $self->{'show_rows'} = shift if (@_);
-
+ if (@_) {
+ $self->{'show_rows'} = shift;
+ $self->RedoSearch();
+ }
return ( $self->{'show_rows'} );
}
@@ -1280,7 +1282,9 @@
=head2 Count
-Returns the number of records in the set.
+Returns the number of records in the record set. If the user has limited down
+to some max number of rows, this should never ever be larger than that number.
+If you want to ignore the search paging, use I<CountAll>
=cut
@@ -1318,8 +1322,7 @@
=head2 CountAll
Returns the total number of potential records in the set, ignoring any
-LimitClause.
-
+search paging.
=cut
# 22:24 [Robrt(500 at outer.space)] It has to do with Caching.
@@ -1347,12 +1350,13 @@
sub CountAll {
my $self = shift;
- # An unlimited search returns no tickets
- return 0 unless ($self->_isLimited);
+ # An unlimited search returns no tickets
+ return 0 unless ( $self->_isLimited );
# If we haven't actually got all objects loaded in memory, we
# really just want to do a quick count from the database.
- if ( $self->{'must_redo_search'} || !$self->{'count_all'}) {
+ if ( $self->{'must_redo_search'} || !$self->{'count_all'} ) {
+
# If we haven't already asked the database for the row count, do that
$self->_DoCount(1) unless ( $self->{'count_all'} );
@@ -1365,6 +1369,7 @@
else {
return ( $self->{'rows'} );
}
+
}
# }}}
Modified: DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle.pm
==============================================================================
--- DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle.pm (original)
+++ DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle.pm Mon Oct 4 16:09:57 2004
@@ -780,7 +780,6 @@
# }}}
-
# {{{ Join
=head2 Join { Paramhash }
@@ -998,7 +997,6 @@
# }}}
-
# {{{ DistinctCount
=head2 DistinctCount STATEMENTREF
Modified: DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle/Sybase.pm
==============================================================================
--- DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle/Sybase.pm (original)
+++ DBIx-SearchBuilder/branches/1.20-SYBASE/SearchBuilder/Handle/Sybase.pm Mon Oct 4 16:09:57 2004
@@ -1,11 +1,10 @@
-# $Header: /home/jesse/DBIx-SearchBuilder/history/SearchBuilder/Handle/Sybase.pm,v 1.8 2001/10/12 05:27:05 jesse Exp $
+use strict;
package DBIx::SearchBuilder::Handle::Sybase;
use DBIx::SearchBuilder::Handle;
- at ISA = qw(DBIx::SearchBuilder::Handle);
+use base qw(DBIx::SearchBuilder::Handle);
-use vars qw($VERSION @ISA $DBIHandle $DEBUG);
-use strict;
+use vars qw($VERSION $DEBUG);
=head1 NAME
@@ -106,8 +105,9 @@
}
-=head2 DistinctQuery STATEMENTREFtakes an incomplete SQL SELECT statement and massages it to return a DISTINCT result set.
+=head2 DistinctQuery STATEMENTREF
+takes an incomplete SQL SELECT statement and massages it to return a DISTINCT result set.
=cut
@@ -136,7 +136,11 @@
return(undef);
}
-# }}}
-# }}}
+=head2 NativeSearchPaging
+
+Sybase can't handle search paging and result set limiting natively.
+
+=cut
+1;
More information about the Rt-commit
mailing list