diff options
author | mkanat%bugzilla.org <> | 2008-01-18 21:56:53 +0000 |
---|---|---|
committer | mkanat%bugzilla.org <> | 2008-01-18 21:56:53 +0000 |
commit | 793c103590ff0742b6163dca25cfc6250c68f803 (patch) | |
tree | 854667752ad8e4377c7bc18c2b40177e7f3083da /Bugzilla/DB.pm | |
parent | Bug 407402: Make Bugzilla die when data/params doesn't exist, if we're in a CGI. (diff) | |
download | bugzilla-793c103590ff0742b6163dca25cfc6250c68f803.tar.gz bugzilla-793c103590ff0742b6163dca25cfc6250c68f803.tar.bz2 bugzilla-793c103590ff0742b6163dca25cfc6250c68f803.zip |
Bug 408172: [Oracle] Bug lists longer than 1000 bugs fail
Patch By Xiaoou Wu <xiaoou.wu@oracle.com> r=mkanat, a=mkanat
Diffstat (limited to 'Bugzilla/DB.pm')
-rw-r--r-- | Bugzilla/DB.pm | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/Bugzilla/DB.pm b/Bugzilla/DB.pm index 40cd3e3a1..2a71bcd75 100644 --- a/Bugzilla/DB.pm +++ b/Bugzilla/DB.pm @@ -391,6 +391,11 @@ sub sql_string_concat { return '(' . join(' || ', @params) . ')'; } +sub sql_in { + my ($self, $column_name, $in_list_ref) = @_; + return " $column_name IN (" . join(',', @$in_list_ref) . ") "; +} + sub sql_fulltext_search { my ($self, $column, $text) = @_; @@ -1918,6 +1923,32 @@ will not be usually used unless it was created as LOWER(column). =back +=item C<sql_in> + +=over + +=item B<Description> + +Returns SQL syntax for the C<IN ()> operator. + +Only necessary where an C<IN> clause can have more than 1000 items. + +=item B<Params> + +=over + +=item C<$column_name> - Column name (e.g. C<bug_id>) + +=item C<$in_list_ref> - an arrayref containing values for C<IN ()> + +=back + +=item B<Returns> + +Formatted SQL for the C<IN> operator. + +=back + =item C<bz_lock_tables> =over |