diff --git a/mozilla/webtools/bugzilla/checksetup.pl b/mozilla/webtools/bugzilla/checksetup.pl index 9a11dc58807..b6722491848 100755 --- a/mozilla/webtools/bugzilla/checksetup.pl +++ b/mozilla/webtools/bugzilla/checksetup.pl @@ -767,7 +767,9 @@ $table{shadowlog} = index(reflected)'; - +$table{product_group} = + 'productid int not null, + userid int not null ########################################################################### # Create tables diff --git a/mozilla/webtools/bugzilla/editnews.cgi b/mozilla/webtools/bugzilla/editnews.cgi new file mode 100755 index 00000000000..27f703812bc --- /dev/null +++ b/mozilla/webtools/bugzilla/editnews.cgi @@ -0,0 +1,372 @@ +#!/usr/bin/perl -w +# -*- Mode: perl; indent-tabs-mode: nil -*- +# +# The contents of this file are subject to the Mozilla Public License +# Version 1.0 (the "License"); you may not use this file except in +# compliance with the License. You may obtain a copy of the License at +# http://www.mozilla.org/MPL/ +# +# Software distributed under the License is distributed on an "AS IS" +# basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the +# License for the specific language governing rights and limitations +# under the License. +# +# +# Direct any questions on this source code to +# +# Holger Schurig +# David Lawrence + +use diagnostics; +use strict; + +require "CGI.pl"; +require "globals.pl"; + +# +# Displays the form to edit news articles +# +sub EmitFormElements { + my ($id, $add_date, $headline, $story) = (@_); + + print qq{ + Headline + + + Story + + +}; + +} + + +# +# Displays a text like "a.", "a or b.", "a, b or c.", "a, b, c or d." +# +sub PutTrailer { + my (@links) = ("Back to the query page", @_); + + my $count = $#links; + my $num = 0; + print "

\n"; + print "

"; + foreach (@links) { + print $_; + if ($num == $count) { + print ".\n"; + } + elsif ($num == $count-1) { + print " or "; + } + else { + print ", "; + } + $num++; + } + print "
\n"; +} + + +# +# Preliminary checks: +# +confirm_login(); + +print "Content-type: text/html\n\n"; + +unless (UserInGroup("addnews")) { + PutHeader("Not allowed"); + print "Sorry, you aren't a member of the 'addnews' group.\n"; + print "And so, you aren't allowed to add, modify or delete news items.\n"; + PutTrailer(); + exit; +} + + +# +# often used variables +# +my $id = trim($::FORM{'id'} || ''); +my $action = trim($::FORM{'action'} || ''); +my $localtrailer = "edit more news items"; + + +# +# action='' -> Show nice list of groups +# +unless ($action) { + PutHeader("Select News Item"); + + if ($::driver eq 'mysql') { + SendSQL("SELECT id, DATE_FORMAT(add_date, '\%b \%d, \%Y \%l:\%i'), headline " . + "FROM news " . + "ORDER BY id"); + } else { + SendSQL("SELECT id, TO_CHAR(add_date, 'MON DD, YYYY HH:MI'), headline, story " . + "FROM news " . + "ORDER BY id"); + } + + print "

\n\n"; + print " \n"; + print " \n"; + print " \n"; + print " \n"; + print ""; + while ( MoreSQLData() ) { + my ($id, $add_date, $headline) = FetchSQLData(); + print "\n"; + print " \n"; + print " \n"; + print " \n"; + print " \n"; + print ""; + } + print "\n"; + print " \n"; + print " \n"; + print "
IDDateHeadlineAction
$id$add_date$headlineDelete
Add a new itemAdd
\n"; + + PutTrailer(); + PutFooter(); + exit; +} + + +# +# action='add' -> present form for parameters for new item +# +# (next action will be 'new') +# +if ($action eq 'add') { + PutHeader("Add News Item"); + + #print "This page lets you add a news item to bugzilla.\n"; + print "

\n"; + print "\n"; + + EmitFormElements('', '', '', \''); + + print "\n
\n"; + print "
\n"; + print "\n"; + print "
"; + + my $other = $localtrailer; + $other =~ s/more/other/; + PutTrailer($other); + PutFooter(); + exit; +} + + +# +# action='new' -> add news item entered in the 'action=add' screen +# +if ($action eq 'new') { + PutHeader("Adding News Item"); + my $headline = trim($::FORM{'headline'} || ''); + my $story = trim($::FORM{'story'} || ''); + + # Cleanups and valididy checks + + unless ($headline) { + print "You must enter a headline for the news item. Please press\n"; + print "Back and try again.\n"; + PutTrailer($localtrailer); + exit; + } + + SendSQL("select id from news where headline = " . SqlQuote($headline)); + my $result = FetchOneColumn(); + if ($result) { + print "The news item '$headline' already exists. Please press\n"; + print "Back and try again.\n"; + PutTrailer($localtrailer); + exit; + } + + + # Add the new group. + if ($::driver eq 'mysql') { + SendSQL("INSERT INTO news ( " . + "add_date, headline, story" . + ") VALUES ( " . + "now(), " . + SqlQuote($headline) . "," . + SqlQuote($story) . ")"); + } else { + SendSQL("INSERT INTO news ( " . + "id, add_date, headline, story" . + ") VALUES ( " . + "news_seq.nextval, sysdate, " . + SqlQuote($headline) . "," . + SqlQuote($story) . ")"); + } + + print "
OK, done.

\n"; + PutTrailer($localtrailer); + exit; +} + + +# +# action='del' -> ask if user really wants to delete +# +# (next action would be 'delete') +# +if ($action eq 'del') { + PutHeader("Delete News Item"); + + # display some data about the news item + if ($::driver eq 'mysql') { + SendSQL("SELECT id, DATE_FORMAT(add_date, '\%b \%d, \%Y \%l:\%i'), headline, story " . + "FROM news " . + "WHERE id = " . $::FORM{'id'}); + } else { + SendSQL("SELECT id, TO_CHAR(add_date, 'MON DD, YYYY HH:MI'), headline, story " . + "FROM news " . + "WHERE id = " . $::FORM{'id'}); + } + + my ($id, $add_date, $headline, $story) = FetchSQLData(); + + print qq{ +

+ + + + + + +
+ $headline
+ Added on $add_date +
+ $story +
+

+}; + + print "

Confirmation

\n"; + print "\n"; + print "

Do you really want to delete this news item?

\n"; + print "

\n"; + print "\n"; + print "\n"; + print "\n"; + print "
"; + + PutTrailer($localtrailer); + PutFooter(); + exit; +} + + +# +# action='delete' -> really delete the news item +# +if ($action eq 'delete') { + PutHeader("Deleting News Item"); + + SendSQL("DELETE FROM news " . + "WHERE id = " . $::FORM{'id'}); + print "
Item deleted.
\n"; + + PutTrailer($localtrailer); + PutFooter(); + exit; +} + + + +# +# action='edit' -> present the edit news item +# +# (next action would be 'update') +# +if ($action eq 'edit') { + PutHeader("Edit News Item"); + + # get data of group + SendSQL("SELECT id, add_date, headline, story " . + "FROM news " . + "WHERE id = " . $::FORM{'id'}); + my ($id, $add_date, $headline, $story) = FetchSQLData(); + + print "
\n"; + print "\n"; + + EmitFormElements($id, $add_date, $headline, \$story); + + print "\n"; + print "
\n"; + + print "\n"; + print "\n"; + print "\n"; + print "\n"; + print "
\n"; + print "
"; + + my $x = $localtrailer; + $x =~ s/more/other/; + PutTrailer($x); + PutFooter(); + exit; +} + + +# +# action='update' -> update the news item +# +if ($action eq 'update') { + PutHeader("Update News Item"); + + my $id = trim($::FORM{'id'}); + my $headlineold = trim($::FORM{'headlineold'} || ''); + my $storyold = trim($::FORM{'storyold'} || ''); + my $headline = trim($::FORM{'headline'} || ''); + my $story = trim($::FORM{'story'} || ''); + + if ($headline ne $headlineold) { + unless ($headline ne "") { + print "Sorry, I can't delete the headline."; + PutTrailer($localtrailer); + exit; + } + SendSQL("UPDATE news " . + "SET headline = " . SqlQuote($headline) . + " WHERE id = $id"); + print "Updated headline.
\n"; + } + + if ($story ne $storyold) { + unless ($story ne "") { + print "Sorry, I can't delete the story."; + PutTrailer($localtrailer); + exit; + } + + SendSQL("UPDATE news " . + "SET story = " . SqlQuote($story) . + " WHERE id = $id"); + print "Updated story.
\n"; + } + + PutTrailer($localtrailer); + exit; +} + + + +# +# No valid action found +# +PutHeader("Error"); +print "I don't have a clue what you want.
\n"; + +foreach ( sort keys %::FORM) { + print "$_: $::FORM{$_}
\n"; +} diff --git a/mozilla/webtools/bugzilla/globals.pl b/mozilla/webtools/bugzilla/globals.pl index c870082c696..f06e1baa873 100644 --- a/mozilla/webtools/bugzilla/globals.pl +++ b/mozilla/webtools/bugzilla/globals.pl @@ -755,6 +755,7 @@ sub GetLongDescriptionAsHTML { return $result; } + sub ShowCcList { my ($num) = (@_); my @ccids; diff --git a/mozilla/webtools/bugzilla/news.cgi b/mozilla/webtools/bugzilla/news.cgi new file mode 100755 index 00000000000..e7b508d7112 --- /dev/null +++ b/mozilla/webtools/bugzilla/news.cgi @@ -0,0 +1,77 @@ +#!/usr/bin/perl -w +# +# news.cgi +# +# Contributor(s) David Lawrence + +require 'CGI.pl'; +require 'globals.pl'; + +print "Content-type: text/html\n\n"; +PutHeader("Bugzilla News"); + + +# subroutine: PutStory +# description: outputs story in table html format +# params: $headline = headline of news article (scalar) +# $date = date news article was created (scalar) +# $story = actual large text of the story (scalar) +# returns: none + +sub PutStory { + my ($add_date, $headline, $story) = (@_); + print qq{ +

+ + + + + + +
+ $headline
+ Added on $add_date +
+ $$story +
+

+}; + +} + + +if (defined ($::FORM{'id'}) && $::FORM{'id'} ne '') { + # Show an individual news article + my $query = ""; + if ($::driver eq 'mysql') { + $query = "select add_date, headline, story from news where id = " . $::FORM{'id'}; + } else { + $query = "select TO_CHAR(add_date, 'YYYY-MM-DD HH:MI:SS'), " . + "headline, story from news " . + "where id = " . $::FORM{'id'}; + } + SendSQL($query); + my ($add_date, $headline, $story) = FetchSQLData(); + PutStory($add_date, $headline, \$story); + +} else { + # Show all the news + print "

All the News...

\n"; + my $query = ""; + if ($::driver eq 'mysql') { + $query = "select id, add_date, headline, story from news order by id"; + } else { + $query = "select id, TO_CHAR(add_date, 'YYYY-MM-DD HH:MI:SS'), " . + "headline, story from news order by id"; + } + SendSQL($query); + while (my @row = FetchSQLData()) { + my ($id, $add_date, $headline, $story) = (@row); + PutStory($add_date, $headline, \$story); + } +} + +PutFooter(); + +exit; + diff --git a/mozilla/webtools/bugzilla/oracle/longdescs_convert.pl b/mozilla/webtools/bugzilla/oracle/longdescs_convert.pl new file mode 100755 index 00000000000..fc5bdd5fbdb --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/longdescs_convert.pl @@ -0,0 +1,167 @@ +#!/usr/bin/perl -w +# +# filename: longdescs_convert.pl +# description: 2000-01-20 Added a new "longdescs" table, which is supposed to have all the +# long descriptions in it, replacing the old long_desc field in the bugs +# table. The below hideous code populates this new table with things from +# the old field, with ugly parsing and heuristics. +# exceptions: Oracle Only! +# contributors: Holger Schurig +# David Lawrence +# + +use DBI; +use Date::Parse; +use Date::Format; + +# database setup +# Connect to Oracle Database +$ENV{'ORACLE_HOME'} = "/opt/oracle/product/805/"; +$ENV{'ORACLE_SID'} = "bugzilla"; +$ENV{'TWO_TASK'} = "bugzilla"; +$ENV{'ORACLE_USERID'} = "bugzilla/bugzilla"; +my $oracle_name = "bugzilla"; +my $oracle_user = "bugzilla/bugzilla"; +my $oracle_date = "SYSDATE"; +my $oracle_dsn = "DBI:Oracle:$oracle_name"; +my $dbh = DBI->connect($oracle_dsn, $oracle_user, '', { RaiseError => 1 }) + || die "Can't connect to database server: " . $DBI::errstr . + " for $oracle_dsn, $oracle_user"; +print "\n\nConnected to Oracle database.\n"; + +$dbh->{LongReadLen} = 1000 * 1024; # large object to read in +$dbh->{LongTruncOk} = 0; # do not truncate + + +# subroutine: WriteOneDesc +# description: Inserts a comment into the new longdescs comments table +# params: $id = current bug number (scalar) +# $who = userid of who created the comment (scalar) +# $when = date when the comment was created (scalar) +# $buffer = the actual text of the comment (scalar) +# returns: none + +sub WriteOneDesc { + my ($id, $who, $when, $buffer) = (@_); + $buffer = trim($buffer); + if ($buffer eq '') { + return; + } + my $query = "INSERT INTO longdescs (bug_id, who, bug_when, thetext) VALUES " . + "($id, $who, TO_DATE(" . + $dbh->quote( time2str('%Y/%m/%d %H:%M:%S', $when) ) . ", 'YYYY-MM-DD HH24:MI:SS'), :1)"; + my $sth = $dbh->prepare($query); + $sth->bind_param(1, $buffer, { SQL_LONGVARCHAR => 1 }); + $sth->execute(); +} + + +# subroutine: trim +# description: Trim whitespace from front and back. +# params: $_ = string to trim whitespace (scalar) +# returns: $_ = string with whitespace removed (scalar) + +sub trim { + ($_) = (@_); + s/^\s+//g; + s/\s+$//g; + return $_; +} + + +my $sth = $dbh->prepare("SELECT count(bug_id) FROM bugs"); +$sth->execute(); +my ($total) = ($sth->fetchrow_array); + +print "Populating new long_desc table. This is slow. There are $total\n"; +print "bugs to process; a line of dots will be printed for each 50.\n\n"; +$| = 1; + +$dbh->do('DELETE FROM longdescs'); + +$sth = $dbh->prepare("SELECT bug_id, TO_CHAR(creation_ts, 'YYYY-MM-DD HH24:MI:SS'), reporter, long_desc " . + "FROM bugs ORDER BY bug_id"); +$sth->execute(); + +my $count = 0; + +while (1) { + my ($id, $createtime, $reporterid, $desc) = ($sth->fetchrow_array()); + if (!$id) { + last; + } + print "."; + $count++; + if ($count % 10 == 0) { + print " "; + if ($count % 50 == 0) { + print "$count/$total (" . int($count * 100 / $total) . "%)\n"; + } + } + $desc =~ s/\r//g; + my $who = $reporterid; + my $when = str2time($createtime); + my $buffer = ""; + foreach my $line (split(/\n/, $desc)) { + $line =~ s/\s+$//g; # Trim trailing whitespace. + if ($line =~ /^------- Additional Comments From ([^\s]+)\s+(\d.+\d)\s+-------$/) { + my $name = $1; + my $date = str2time($2); + $date += 59; # Oy, what a hack. The creation time is + # accurate to the second. But we the long + # text only contains things accurate to the + # minute. And so, if someone makes a comment + # within a minute of the original bug creation, + # then the comment can come *before* the + # bug creation. So, we add 59 seconds to + # the time of all comments, so that they + # are always considered to have happened at + # the *end* of the given minute, not the + # beginning. + if ($date >= $when) { + WriteOneDesc($id, $who, $when, $buffer); + $buffer = ""; + $when = $date; + my $s2 = $dbh->prepare("SELECT userid FROM profiles " . + "WHERE login_name = " . + $dbh->quote($name)); + $s2->execute(); + ($who) = ($s2->fetchrow_array()); + if (!$who) { + # This username doesn't exist. Try a special + # netscape-only hack (sorry about that, but I don't + # think it will hurt any other installations). We + # have many entries in the bugsystem from an ancient + # world where the "@netscape.com" part of the loginname + # was omitted. So, look up the user again with that + # appended, and use it if it's there. + if ($name !~ /\@/) { + my $nsname = $name . "\@netscape.com"; + $s2 = + $dbh->prepare("SELECT userid FROM profiles " . + "WHERE login_name = " . + $dbh->quote($nsname)); + $s2->execute(); + ($who) = ($s2->fetchrow_array()); + } + } + + if (!$who) { + # This username doesn't exist. Maybe someone renamed + # him or something. Use a summy profile (Anonymous) + # since we used to allow anonymous comments. + ($who) = '4424'; # userid of user 'Anonymous' + } + next; + } else { +# print "\nDecided this line of bug $id has a date of " . +# time2str("'%Y/%m/%d %H:%M:%S'", $date) . +# "\nwhich is less than previous line:\n$line\n\n"; + } + + } + $buffer .= $line . "\n"; + } + WriteOneDesc($id, $who, $when, $buffer); +} + diff --git a/mozilla/webtools/bugzilla/oracle/makeactivitytable.sql b/mozilla/webtools/bugzilla/oracle/makeactivitytable.sql new file mode 100755 index 00000000000..9997074fd32 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeactivitytable.sql @@ -0,0 +1,18 @@ +rem Creates the bug activity table +rem Contributed by David Lawrence + +drop table bugs_activity; +drop index bugact_index; + +create table bugs_activity ( + bug_id INTEGER CONSTRAINT ACT_NN_BUGID NOT NULL, + who INTEGER CONSTRAINT ACT_NN_WHO NOT NULL, + bug_when DATE CONSTRAINT ACT_NN_WHEN NOT NULL, + field VARCHAR2(64) CONSTRAINT ACT_NN_FIELD NOT NULL, + oldvalue VARCHAR2(400) , + newvalue VARCHAR2(400) +); + +create index bugact_index on bugs_activity (bug_id, bug_when); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeattachmenttable.sql b/mozilla/webtools/bugzilla/oracle/makeattachmenttable.sql new file mode 100755 index 00000000000..4ad5184cbf3 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeattachmenttable.sql @@ -0,0 +1,23 @@ +rem Table to hold attachements to bugs +rem Contributed by David Lawrence + +drop table attachments; +drop sequence attachid_seq; +drop index attach_index; + +create table attachments ( + attach_id INTEGER CONSTRAINT ATTACH_PK_ATTACHID PRIMARY KEY NOT NULL, + bug_id INTEGER CONSTRAINT ATTACH_NN_BUGID NOT NULL, + creation_ts DATE CONSTRAINT ATTACH_NN_CREATION NOT NULL, + description VARCHAR2(2000) CONSTRAINT ATTACH_NN_DESC NOT NULL, + mimetype VARCHAR2(255) CONSTRAINT ATTACH_NN_MIME NOT NULL, + ispatch INTEGER , + filename VARCHAR2(255) CONSTRAINT ATTACH_NN_FILE NOT NULL, + thedata BLOB CONSTRAINT ATTACH_NN_DATA NOT NULL, + submitter_id INTEGER CONSTRAINT ATTACH_NN_SUBMIT NOT NULL +); + +create sequence attachid_seq NOCACHE START WITH 1 INCREMENT BY 1; +create index attach_index on attachments (bug_id, creation_ts); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makebuggrouptable.sql b/mozilla/webtools/bugzilla/oracle/makebuggrouptable.sql new file mode 100755 index 00000000000..2bbf2071d29 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makebuggrouptable.sql @@ -0,0 +1,14 @@ +rem * Table to hold valid bug class values in bugzilla +rem * Contributed by David Lawrence + +drop table bug_group; +drop index buggroup_index; + +create table bug_group ( + bugid INTEGER CONSTRAINT BUGGROUP_NN_BUGID NOT NULL, + groupid INTEGER CONSTRAINT BUGGROUP_NN_GROUPID NOT NULL +); + +create index buggroup_index on bug_group (bugid, groupid); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makebugstatustable.sql b/mozilla/webtools/bugzilla/oracle/makebugstatustable.sql new file mode 100755 index 00000000000..949f7f88988 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makebugstatustable.sql @@ -0,0 +1,18 @@ +rem * Table to hold valid bug status values in bugzilla +rem * Contributed by David Lawrence + +drop table bug_status; + +create table bug_status ( + id INTEGER CONSTRAINT STATUS_PK_ID PRIMARY KEY NOT NULL, + value VARCHAR(255) CONSTRAINT STATUS_NN_VALUE NOT NULL +); + +rem insert into bug_status (id, value) values ('1', 'NEW'); +rem insert into bug_status (id, value) values ('2', 'VERIFIED'); +rem insert into bug_status (id, value) values ('3', 'ASSIGNED'); +rem insert into bug_status (id, value) values ('4', 'REOPENED'); +rem insert into bug_status (id, value) values ('5', 'RESOLVED'); +rem insert into bug_status (id, value) values ('6', 'CLOSED'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makebugtable.sql b/mozilla/webtools/bugzilla/oracle/makebugtable.sql new file mode 100755 index 00000000000..1311671f5a9 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makebugtable.sql @@ -0,0 +1,56 @@ +rem The big bugs table +rem Contributed by David Lawrence + +drop table bugs; +drop index bugs_index; +drop sequence bugs_seq; + +create table bugs ( + bug_id INTEGER CONSTRAINT BUGS_PK_BUGID PRIMARY KEY NOT NULL, + groupset INTEGER DEFAULT('0'), + group_id INTEGER DEFAULT('0'), + assigned_to INTEGER CONSTRAINT BUGS_NN_ASSITO NOT NULL, + bug_file_loc VARCHAR2(255) DEFAULT(''), + patch_file_loc VARCHAR2(255) DEFAULT(''), + bug_severity VARCHAR2(64) CONSTRAINT BUGS_NN_SEVRTY NOT NULL, + bug_status VARCHAR2(64) CONSTRAINT BUGS_NN_STATUS NOT NULL, + bug_view INTEGER DEFAULT('0'), + creation_ts DATE CONSTRAINT BUGS_NN_CRTETS NOT NULL, + delta_ts DATE, + short_desc VARCHAR2(4000) CONSTRAINT BUGS_NN_SHORT NOT NULL, + long_desc LONG DEFAULT(''), + op_sys VARCHAR2(64) DEFAULT('Linux'), + priority VARCHAR2(64) CONSTRAINT BUGS_NN_PRIRTY NOT NULL, + product VARCHAR2(256) CONSTRAINT BUGS_NN_PRODCT NOT NULL, + rep_platform VARCHAR2(64) CONSTRAINT BUGS_NN_PLATFM NOT NULL, + reporter INTEGER CONSTRAINT BUGS_NN_REPRTR NOT NULL, + version VARCHAR2(64) CONSTRAINT BUGS_NN_VERSN NOT NULL, + release VARCHAR2(64) DEFAULT(''), + component VARCHAR2(64) CONSTRAINT BUGS_NN_COMPNT NOT NULL, + resolution VARCHAR2(64) DEFAULT(''), + class VARCHAR2(255) DEFAULT(''), + target_milestone VARCHAR2(64) DEFAULT(''), + qa_contact VARCHAR2(255) DEFAULT(''), + status_whiteboard VARCHAR2(4000) DEFAULT(''), + votes INTEGER DEFAULT('0'), + keywords VARCHAR(255) DEFAULT(''), + lastdiffed DATE +); + +create sequence bugs_seq NOCACHE START WITH 1 INCREMENT BY 1; +create index bugs_index on bugs (assigned_to, + creation_ts, + delta_ts, + bug_severity, + bug_status, + op_sys, + priority, + product, + reporter, + version, + component, + resolution, + target_milestone, + qa_contact); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makecctable.sql b/mozilla/webtools/bugzilla/oracle/makecctable.sql new file mode 100755 index 00000000000..9fedd8d73c5 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makecctable.sql @@ -0,0 +1,15 @@ +rem Table to hold list of cc persons for particular bug +rem Contributed by David Lawrence + +drop table cc; +drop index cc_index; + +create table cc ( + bug_id INTEGER CONSTRAINT CC_NN_BUGID NOT NULL, + who INTEGER CONSTRAINT CC_NN_WHO NOT NULL +); + +create index cc_index on cc (bug_id, who); + +exit; + diff --git a/mozilla/webtools/bugzilla/oracle/makeclasstable.sql b/mozilla/webtools/bugzilla/oracle/makeclasstable.sql new file mode 100755 index 00000000000..69166f1e050 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeclasstable.sql @@ -0,0 +1,17 @@ +rem * Table to hold valid bug class values in bugzilla +rem * Contributed by David Lawrence + +drop table class; + +create table class ( + id INTEGER CONSTRAINT CLASS_PK_ID PRIMARY KEY, + value VARCHAR(255) CONSTRAINT CLASS_NN_VALUE NOT NULL +); + +rem insert into class (id, value) values ('1', 'install/upgrade'); +rem insert into class (id, value) values ('2', 'packaging'); +rem insert into class (id, value) values ('3', 'functionality'); +rem insert into class (id, value) values ('4', 'security'); +rem insert into class (id, value) values ('5', 'documentation'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makecomponenttable.sql b/mozilla/webtools/bugzilla/oracle/makecomponenttable.sql new file mode 100755 index 00000000000..e81b8735bc1 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makecomponenttable.sql @@ -0,0 +1,19 @@ +rem Table to hold component information divided by product +rem Contributed by David Lawrence + +drop table components; + +create table components ( + value VARCHAR2(255) CONSTRAINT COMP_NN_VALUE NOT NULL, + program VARCHAR2(255) CONSTRAINT COMP_NN_PROGRM NOT NULL, + initialowner VARCHAR2(64) CONSTRAINT COMP_NN_INTOWN NOT NULL, + devowner VARCHAR2(64), + initialqacontact VARCHAR2(64), + description VARCHAR2(2000) +); + +rem insert into components (value, program, initialowner, description) +rem values ('TestComponent', 'TestProduct', 'dkl@redhat.com', +rem 'This is a test component in the test product database. This ought to be blown away and replaced with real stuffrem in a finished installation of bugzilla.'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makedependenciestable.sql b/mozilla/webtools/bugzilla/oracle/makedependenciestable.sql new file mode 100755 index 00000000000..1afaf07a007 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makedependenciestable.sql @@ -0,0 +1,14 @@ +rem Table to hold bug report dependency information +rem Contributed by David Lawrence + +drop table dependencies; +drop index depend_index; + +create table dependencies ( + blocked INTEGER CONSTRAINT DEPEND_NN_BLOCKED NOT NULL, + dependson INTEGER CONSTRAINT DEPEND_NN_DPNDSON NOT NULL +); + +create index depend_index on dependencies (blocked, dependson); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeemailtable.sql b/mozilla/webtools/bugzilla/oracle/makeemailtable.sql new file mode 100755 index 00000000000..1f2454624bd --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeemailtable.sql @@ -0,0 +1,15 @@ +rem * Table to hold valid email choices values in bugzilla +rem * Contributed by David Lawrence + +drop table emailnotification; + +create table emailnotification ( + id INTEGER CONSTRAINT EMAIL_PK_ID PRIMARY KEY NOT NULL, + value VARCHAR(255) CONSTRAINT EMAIL_NN_VALUE NOT NULL +); + +rem insert into emailnotification (id, value) values ('1', 'ExcludeSelfChanges'); +rem insert into emailnotification (id, value) values ('2', 'CConly'); +rem insert into emailnotification (id, value) values ('3', 'All'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makefielddefs.sql b/mozilla/webtools/bugzilla/oracle/makefielddefs.sql new file mode 100755 index 00000000000..0f19e670366 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makefielddefs.sql @@ -0,0 +1,21 @@ +rem create script for fielddefs table +rem Cotributed by David Lawrence + +drop table fielddefs; + +create table fielddefs ( + fieldid INTEGER CONSTRAINT FIELDDEF_PK_ID PRIMARY KEY NOT NULL, + name VARCHAR2(64) CONSTRAINT FIELDDEF_NN_NAME NOT NULL, + description VARCHAR2(255) CONSTRAINT FIELDDEF_NN_DESC NOT NULL, + mailhead INTEGER DEFAULT ('0'), + sortkey INTEGER CONSTRAINT FIELDDEF_NN_SORT NOT NULL +); + +create index fielddefs_index on fielddefs (sortkey); + +drop sequence fielddefs.seq; + +create sequence fielddefs_seq START WITH 1 INCREMENT BY 1; + +exit; + diff --git a/mozilla/webtools/bugzilla/oracle/makegroupstable.sql b/mozilla/webtools/bugzilla/oracle/makegroupstable.sql new file mode 100755 index 00000000000..8e44b2b04ba --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makegroupstable.sql @@ -0,0 +1,30 @@ +rem Table to hold bugzilla group information +rem Contributed by David Lawrence + +drop table groups; + +create table groups ( + bit INTEGER DEFAULT('0'), + groupid INTEGER CONSTRAINT GROUPS_PK_GROUPID PRIMARY KEY NOT NULL, + name VARCHAR2(255) CONSTRAINT GROUPS_NN_NAME NOT NULL, + description VARCHAR2(2000) CONSTRAINT GROUPS_NN_DESC NOT NULL, + isbuggroup INTEGER CONSTRAINT GROUPS_NN_BUGGRP NOT NULL, + userregexp VARCHAR2(255), + contract INTEGER CONSTRAINT GROUPS_NN_CONTACT NOT NULL +); + +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (1, 1, 'tweakparams', 'Can tweak operating parameters', 0, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (2, 2, 'editgroupmembers', 'Can put people in and out of groups that they are members of.', 0, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (4, 3, 'creategroups', 'Can create and destroy groups.', 0, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (8, 4, 'editcomponents', 'Can create, destroy, and edit components.', 0, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (16, 5, 'support', 'Red Hat Technical Supprt', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (32, 6, 'qa', 'Red Hat Quality Assurance', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (64, 7, 'devel', 'Red Hat Development', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (128, 8, 'marketing', 'Red Hat Marketing', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (256, 9, 'web', 'Red Hat Web Group', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (512, 10, 'beta', 'Red Hat Beta Program', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (1024, 11, 'intel', 'Intel Confidential Group', 1, '', 1); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (2048, 12, 'errata', 'Red Hat Errata Group', 1, '', 0); +rem insert into groups (bit, groupid, name, description, isbuggroup, userregexp, contract) values (4096, 13, 'setcontract', 'Can set a bug report to contract priority', 1, '', 0); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makekeyworddef.sql b/mozilla/webtools/bugzilla/oracle/makekeyworddef.sql new file mode 100755 index 00000000000..fa51ba542f8 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makekeyworddef.sql @@ -0,0 +1,12 @@ +rem table to hold keyword definitions +rem Contributed by David Lawrence + +drop table keyworddefs; + +create table keyworddefs ( + id INTEGER CONSTRAINT KEYDEF_PK_ID PRIMARY KEY NOT NULL, + name VARCHAR2(64) CONSTRAINT KEYDEF_NN_NAME NOT NULL, + description VARCHAR2(2000) +); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makekeywords.sql b/mozilla/webtools/bugzilla/oracle/makekeywords.sql new file mode 100755 index 00000000000..aeaaa2090b4 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makekeywords.sql @@ -0,0 +1,14 @@ +rem table to hold keywords +rem Contributed by David Lawrence + +drop table keywords; +drop index keywords_index; + +create table keywords ( + bug_id INTEGER CONSTRAINT KEYWORDS_NN_BUGID NOT NULL, + keywordid INTEGER CONSTRAINT KEYWORDS_NN_KEYID NOT NULL +); + +create index keywords_index on keywords (bug_id, keywordid); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makelogincookiestable.sql b/mozilla/webtools/bugzilla/oracle/makelogincookiestable.sql new file mode 100755 index 00000000000..657649e3f17 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makelogincookiestable.sql @@ -0,0 +1,20 @@ +rem * Table to hold login cookie information for user authentification +rem * Contributed by David Lawrence + +drop table logincookies; +drop index login_index; +drop sequence login_seq; + +create table logincookies ( + cookie INTEGER CONSTRAINT LOGIN_PK_COOKIE PRIMARY KEY, + userid INTEGER CONSTRAINT LOGIN_NN_USERID NOT NULL, + cryptpassword VARCHAR2(64), + hostname VARCHAR2(128), + lastused DATE +); + +create index login_index on logincookies (lastused); + +create sequence login_seq NOCACHE START WITH 1 INCREMENT BY 1; + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makelongdesctable.sql b/mozilla/webtools/bugzilla/oracle/makelongdesctable.sql new file mode 100755 index 00000000000..a754572e9ac --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makelongdesctable.sql @@ -0,0 +1,16 @@ +rem * Table to hold valid bug class values in bugzilla +rem * Contributed by David Lawrence + +drop table longdescs; +drop index longdescs_index; + +create table longdescs ( + bug_id INTEGER CONSTRAINT LONG_NN_BUGID NOT NULL, + who INTEGER CONSTRAINT LONG_NN_WHO NOT NULL, + bug_when DATE CONSTRAINT LONG_NN_WHEN NOT NULL, + thetext LONG +); + +create index longdescs_index on longdescs (bug_id, bug_when); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeopsystable.sql b/mozilla/webtools/bugzilla/oracle/makeopsystable.sql new file mode 100755 index 00000000000..4aa7146a4a4 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeopsystable.sql @@ -0,0 +1,13 @@ +rem * Table to hold valid op sys values in bugzilla +rem * Contributed by David Lawrence + +drop table op_sys; + +create table op_sys ( + id INTEGER CONSTRAINT OPSYS_PK_ID PRIMARY KEY, + value VARCHAR2(255) CONSTRAINT OPSYS_NN_VALUE NOT NULL +); + +rem insert into op_sys (id, value) values ('1', 'Linux'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeprioritytable.sql b/mozilla/webtools/bugzilla/oracle/makeprioritytable.sql new file mode 100755 index 00000000000..ccc928d689d --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeprioritytable.sql @@ -0,0 +1,16 @@ +rem * Table to hold valid priority values in bugzilla +rem * Contributed by David Lawrence + +drop table priority; + +create table priority ( + id INTEGER CONSTRAINT PRIORITY_PK_ID PRIMARY KEY NOT NULL, + value VARCHAR(255) CONSTRAINT PRIORITY_NN_VALUE NOT NULL +); + +rem insert into priority (id, value) values ('1', 'high'); +rem insert into priority (id, value) values ('2', 'normal'); +rem insert into priority (id, value) values ('3', 'low'); +rem insert into priority (id, value) values ('4', 'contract'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeproductgroup.sql b/mozilla/webtools/bugzilla/oracle/makeproductgroup.sql new file mode 100755 index 00000000000..aeeded591fb --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeproductgroup.sql @@ -0,0 +1,15 @@ +rem * Table to hold valid bug class values in bugzilla +rem * Contributed by David Lawrence + +drop table product_group; +drop index product_index; + +create table product_group ( + productid INTEGER CONSTRAINT PRODGROUP_NN_PRODID NOT NULL, + groupid INTEGER CONSTRAINT PRODGROUP_NN_GROUPID NOT NULL +); + +create index prodgroup_index on product_group (productid, groupid); + +exit; + diff --git a/mozilla/webtools/bugzilla/oracle/makeproducttable.sql b/mozilla/webtools/bugzilla/oracle/makeproducttable.sql new file mode 100755 index 00000000000..1b12114780a --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeproducttable.sql @@ -0,0 +1,20 @@ +rem * Table to hold the current list of products in bugzilla +rem * Contributed by David Lawrence + +drop table products; +drop sequence product_seq; + +create table products ( + product VARCHAR2(255) CONSTRAINT PRODUCT_NN_PRODUCT NOT NULL, + description VARCHAR2(2000) CONSTRAINT PRODUCT_NN_DESC NOT NULL, + milestoneurl VARCHAR2(255), + disallownew VARCHAR2(255), + votesperuser INTEGER, + id INTEGER CONSTRAINT PRODUCT_PK_ID PRIMARY KEY NOT NULL +); + +create sequence product_seq NOCACHE START WITH 1 INCREMENT BY 1; + +rem insert into products(product, description, id) values ('TestProduct', 'This is a test product. This ought to be blown away and replaced with real stuff in a finished installation of bugzilla.', product_seq.nextval); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeprofilestable.sql b/mozilla/webtools/bugzilla/oracle/makeprofilestable.sql new file mode 100755 index 00000000000..f4add4b68fb --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeprofilestable.sql @@ -0,0 +1,26 @@ +rem * Table to hold all the valid members of bugzilla and their information +rem * Contributed by David Lawrence + +drop table profiles; +drop index profiles_index; +drop sequence profiles_seq; + +create table profiles ( + userid INTEGER CONSTRAINT PROFILE_PK_USRID PRIMARY KEY, + login_name VARCHAR2(255) CONSTRAINT PROFILE_NN_LOGIN NOT NULL, + password VARCHAR2(16) CONSTRAINT PROFILE_NN_PASSWD NOT NULL, + cryptpassword VARCHAR2(64) CONSTRAINT PROFILE_NN_CRYPT NOT NULL, + realname VARCHAR2(255), + groupid INTEGER DEFAULT(0), + groupset INTEGER DEFAULT(0), + emailnotification VARCHAR2(30) DEFAULT('ExcludeSelfChanges'), + disabledtext VARCHAR2(255), + newemailtech INTEGER, + mybugslink INTEGER DEFAULT('1') +); + +create sequence profiles_seq NOCACHE START WITH 1 INCREMENT BY 1; + +create index profiles_index on profiles (login_name); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makequerytable.sql b/mozilla/webtools/bugzilla/oracle/makequerytable.sql new file mode 100755 index 00000000000..09335bcb353 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makequerytable.sql @@ -0,0 +1,15 @@ +rem * Table to hold valid member queries in bugzilla +rem * Contributed by David Lawrence + +drop table queries ; +drop index queries_index; + +create table queries ( + userid INTEGER CONSTRAINT QUERY_NN_USRID NOT NULL, + query_name VARCHAR2(255) CONSTRAINT QUERY_NN_NAME NOT NULL, + query LONG CONSTRAINT QUERY_NN_QUERY NOT NULL +); + +create index queries_index on queries (query_name); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makerepplatformtable.sql b/mozilla/webtools/bugzilla/oracle/makerepplatformtable.sql new file mode 100755 index 00000000000..6709e359e30 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makerepplatformtable.sql @@ -0,0 +1,17 @@ +rem * Table to hold valid rep platform values in bugzilla +rem * Contributed by David Lawrence + +drop table rep_platform; + +create table rep_platform ( + id INTEGER CONSTRAINT PLATFM_PK_ID PRIMARY KEY, + value VARCHAR(255) CONSTRAINT PLATFM_NN_VALUE NOT NULL +); + +rem insert into rep_platform (id, value) values ('1', 'All'); +rem insert into rep_platform (id, value) values ('2', 'i386'); +rem insert into rep_platform (id, value) values ('3', 'alpha'); +rem insert into rep_platform (id, value) values ('4', 'sparc'); +rem insert into rep_platform (id, value) values ('5', 'noarch'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeresolutiontable.sql b/mozilla/webtools/bugzilla/oracle/makeresolutiontable.sql new file mode 100755 index 00000000000..d5f1872b1a7 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeresolutiontable.sql @@ -0,0 +1,21 @@ +rem * Table to hold valid bug resolution values in bugzilla +rem * Contributed by David Lawrence + +drop table resolution; + +create table resolution ( + id INTEGER CONSTRAINT RESO_PK_ID PRIMARY KEY, + value VARCHAR2(255) +); + +rem insert into resolution (id, value) values ('1', 'NOTABUG'); +rem insert into resolution (id, value) values ('2', 'WONTFIX'); +rem insert into resolution (id, value) values ('3', 'DEFERRED'); +rem insert into resolution (id, value) values ('4', 'WORKSFORME'); +rem insert into resolution (id, value) values ('5', 'CURRENTRELEASE'); +rem insert into resolution (id, value) values ('6', 'RAWHIDE'); +rem insert into resolution (id, value) values ('7', 'ERRATA'); +rem insert into resolution (id, value) values ('8', 'DUPLICATE'); +rem insert into resolution (id, value) values ('9', ''); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeseveritytable.sql b/mozilla/webtools/bugzilla/oracle/makeseveritytable.sql new file mode 100755 index 00000000000..c7948a35181 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeseveritytable.sql @@ -0,0 +1,17 @@ +rem * Table to hold valid bug severity values in bugzilla +rem * Contributed by David Lawrence + +drop table bug_severity; + +create table bug_severity ( + id INTEGER CONSTRAINT SEVERE_PK_ID PRIMARY KEY, + value VARCHAR(255) CONSTRAINT SEVERE_NN_VALUE NOT NULL +); + +rem insert into bug_severity (id, value) values ('1', 'security'); +rem insert into bug_severity (id, value) values ('2', 'high'); +rem insert into bug_severity (id, value) values ('3', 'normal'); +rem insert into bug_severity (id, value) values ('4', 'low'); +rem insert into bug_severity (id, value) values ('5', 'enhancement'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeusergroup.sql b/mozilla/webtools/bugzilla/oracle/makeusergroup.sql new file mode 100755 index 00000000000..58fa66c83cb --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeusergroup.sql @@ -0,0 +1,28 @@ +rem * Table to hold valid user group values in bugzilla +rem * Contributed by David Lawrence + +drop table user_group; +drop index usergroup_index; + +create table user_group ( + userid INTEGER CONSTRAINT USERGROUP_NN_BUGID NOT NULL, + groupid INTEGER CONSTRAINT USERGROUP_NN_GROUPID NOT NULL +); + +create index usergroup_index on user_group (userid, groupid); + +rem insert into user_group values (1, 1); +rem insert into user_group values (1, 2); +rem insert into user_group values (1, 3); +rem insert into user_group values (1, 4); +rem insert into user_group values (1, 5); +rem insert into user_group values (1, 6); +rem insert into user_group values (1, 7); +rem insert into user_group values (1, 8); +rem insert into user_group values (1, 9); +rem insert into user_group values (1, 10); +rem insert into user_group values (1, 11); +rem insert into user_group values (1, 12); +rem insert into user_group values (1, 13); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makeversiontable.sql b/mozilla/webtools/bugzilla/oracle/makeversiontable.sql new file mode 100755 index 00000000000..6b8eb118b93 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makeversiontable.sql @@ -0,0 +1,13 @@ +rem * Table to hold valid product versions in bugzilla +rem * Contributed by David Lawrence + +drop table versions; + +create table versions ( + value VARCHAR2(255) CONSTRAINT VERS_NN_VALUE NOT NULL, + program VARCHAR2(255) CONSTRAINT VERS_NN_PROGM NOT NULL +); + +rem insert into versions (value, program) values ('other', 'TestProduct'); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/makevotestable.sql b/mozilla/webtools/bugzilla/oracle/makevotestable.sql new file mode 100755 index 00000000000..7cec2127662 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/makevotestable.sql @@ -0,0 +1,12 @@ +rem * Table to hold bug vote information in bugzilla +rem * Contributed by David Lawrence + +drop table votes; + +create table votes ( + who INTEGER CONSTRAINT VOTE_NN_WHO NOT NULL, + bug_id INTEGER CONSTRAINT VOTE_NN_BUGID NOT NULL, + count INTEGER CONSTRAINT VOTE_NN_COUNT NOT NULL +); + +exit; diff --git a/mozilla/webtools/bugzilla/oracle/migrate_all.pl b/mozilla/webtools/bugzilla/oracle/migrate_all.pl new file mode 100755 index 00000000000..ec689272c37 --- /dev/null +++ b/mozilla/webtools/bugzilla/oracle/migrate_all.pl @@ -0,0 +1,395 @@ +#!/usr/bin/perl -w +# +# migrate.pl +# + +use DBI; +use DBD::Oracle qw{:ora_types}; + +# database setup +# Connect to Oracle Database +$ENV{'ORACLE_HOME'} = "/opt/oracle/product/805/"; +$ENV{'ORACLE_SID'} = "bugzilla"; +$ENV{'TWO_TASK'} = "bugzilla"; +$ENV{'ORACLE_USERID'} = "bugzilla/bugzilla"; +my $oracle_name = "bugzilla"; +my $oracle_user = "bugzilla/bugzilla"; +my $oracle_date = "SYSDATE"; +my $oracle_dsn = "DBI:Oracle:$oracle_name"; +my $oracle_dbh = DBI->connect($oracle_dsn, $oracle_user, '', { RaiseError => 1 }) + || die "Can't connect to database server: " . $DBI::errstr . + " for $oracle_dsn, $oracle_user"; +print "\n\nConnected to Oracle database.\n"; + +$oracle_dbh->{LongReadLen} = 1000 * 1024; # large object +$oracle_dbh->{LongTruncOk} = 0; # do not truncate + +# Connect to Mysql Database +my $mysql_name = "bugs"; +my $mysql_user = "bugs"; +my $mysql_dsn = "DBI:mysql:$mysql_name"; +my $mysql_date = "now()"; +$mysql_dbh = DBI->connect($mysql_dsn, $mysql_user, '', { RaiseError => 1}) + || die "Can't connect to database server: " . $DBI::errstr . + " for $mysql_dsn, $mysql_user"; +$mysql_dbh->{LongReadLen} = 1000 * 1024; # large object +$mysql_dbh->{LongTruncOk} = 0; # do not truncate +print "Connected to MySQL database.\n"; + +my $query = ""; +my $mysql_sth = ""; +my $oracle_sth = ""; +my $count = 1; + +# grab a list of tables in mysql database +my %tables; +$query = "show tables"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); +while (my @row = $mysql_sth->fetchrow_array()) { + $tables{$row[0]} = []; +} + +#grab the columns associated with each of the tables +foreach my $table (keys %tables) { + $query = "show columns from $table"; + $mysql_sth = $mysql_dbh->prepare($query); + $mysql_sth->execute(); + while (my @row = $mysql_sth->fetchrow_array()) { + push (@{$tables{$table}}, $row[0]); + } +} + +# print the table information +#foreach my $table (keys %tables) { +# print "\n$table\n"; +# foreach my $column (@{$tables{$table}}) { +# print "\t$column\n"; +# } +#} + + +# for each table form insert statements in Oracle +foreach my $table (keys %tables) { + if ($table eq "bugs" || + $table eq "bugs_activity" || + $table eq "attachments" || + $table eq "longdescs" || + $table eq "logincookies" || + $table eq "errata" || + $table eq "type" || + $table eq "queries") { + next; + } + $query = "select " . join (", ", @{$tables{$table}}) . + " from $table"; + $mysql_sth = $mysql_dbh->prepare($query); + $mysql_sth->execute(); + while (my @row = $mysql_sth->fetchrow_array()) { + my @quoted = (); + foreach my $field (@row) { + push (@quoted, $oracle_dbh->quote($field)); + } + $query = "insert into $table (" . join (", ", @{$tables{$table}}) . + ") values (" . join (", ", @quoted) . ")"; + # print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); + print "$count entry added to $table\n"; + $count++; + } +} + + +# logincookies +@columns = ( 'cookie', + 'userid', + 'cryptpassword', + 'hostname', + 'lastused'); + +$query = "select " . join (', ', @columns) . " from logincookies"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); + +$count = 1; +print "\n\n"; + +while (my @row = $mysql_sth->fetchrow_array()) { + my $cookie = $oracle_dbh->quote($row[0]); + my $userid = $oracle_dbh->quote($row[1]); + my $cryptpassword = $oracle_dbh->quote($row[2]); + my $hostname = $oracle_dbh->quote($row[3]); + my $lastused = "TO_DATE(" . $oracle_dbh->quote($row[4]) . ", 'YYYYMMDDHH24MISS')"; + + $query = "insert into logincookies ( " . + join (', ', @columns) . " ) " . + "values ($cookie, $userid, $cryptpassword, " . + "$hostname, $lastused)"; + # print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); + print "$count entry added to logincookies\n"; + $count++; +} + + +# bugs_activity +@columns = ( 'bug_id', + 'who', + 'bug_when', + 'field', + 'oldvalue', + 'newvalue' ); + +$query = "select " . join (', ', @columns) . " from bugs_activity"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); + +$count = 1; +print "\n\n"; + +while (my @row = $mysql_sth->fetchrow_array()) { + my $bug_id = $oracle_dbh->quote($row[0]); + my $who = $oracle_dbh->quote($row[1]); + my $bug_when = "TO_DATE(" . + $oracle_dbh->quote($row[2]) . ", 'YYYY-MM-DD HH24:MI:SS')"; + my $field = $oracle_dbh->quote($row[3]); + if (!defined($row[4])) { + $row[4] = ""; + } + my $oldvalue = $oracle_dbh->quote($row[4]); + if (!defined($row[5])) { + $row[5] = ""; + } + my $newvalue = $oracle_dbh->quote($row[5]); + + $query = "insert into bugs_activity ( " . + join (', ', @columns) . " ) " . + "values ($bug_id, $who, $bug_when, " . + "$field, $oldvalue, $newvalue)"; + # print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); + print "$count entry added to bugs_activity\n"; + $count++; +} + + +# queries +$query = "select userid, query_name, query from queries"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); + +$count = 1; +print "\n\n"; + +while (my @row = $mysql_sth->fetchrow_array()) { + my $userid = $mysql_dbh->quote($row[0]); + my $query_name = $mysql_dbh->quote($row[1]); + my $query_long = $mysql_dbh->quote($row[2]); + $oracle_sth = $oracle_dbh->prepare("insert into queries (userid, query_name, query) values ($userid, $query_name, ?)"); + $oracle_sth->bind_param(1, $query_long, { SQL_LONGVARCHAR => 1}); + $oracle_sth->execute(); + print "$count entry added to queries\n"; + $count++; +} + + +# attachments +@columns = ( 'attach_id', + 'bug_id', + 'creation_ts', + 'description', + 'mimetype', + 'ispatch', + 'filename', + 'thedata', + 'submitter_id' ); + +$query = "select " . join (', ', @columns) . " from attachments"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); + +$count = 1; +print "\n\n"; + +while (my @row = $mysql_sth->fetchrow_array()) { + my $attach_id = $oracle_dbh->quote($row[0]); + my $bug_id = $oracle_dbh->quote($row[1]); + my $creation_ts = "TO_DATE(" . $oracle_dbh->quote($row[2]) . ", 'YYYYMMDDHH24MISS')"; + my $desc = $oracle_dbh->quote($row[3]); + my $mime = $oracle_dbh->quote($row[4]); + my $ispatch = $oracle_dbh->quote($row[5]); + my $filename = $oracle_dbh->quote($row[6]); +# my $thedata = $oracle_dbh->quote( pack ('H*', $row[7]) ); + my $thedata = $oracle_dbh->quote($row[7]); + my $submitter = $oracle_dbh->quote($row[8]); + + $query = "insert into attachments ( " . join (', ', @columns) . " ) " . + "values ($attach_id, $bug_id, $creation_ts, $desc, $mime, " . + "$ispatch, $filename, :1, $submitter)"; + # print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->bind_param(1, $thedata, { ora_field => 'thedata', ora_type => ORA_BLOB }); + $oracle_sth->execute(); + print "$count entry added to attachments\n"; + $count++; +} + + +# long descriptions +@columns = ( 'bug_id', + 'who', + 'bug_when', + 'thetext'); + +$query = "select " . join (', ', @columns) . " from longdescs"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); + +$count = 1; +print "\n\n"; + +while (my @row = $mysql_sth->fetchrow_array()) { + my $bug_id = $oracle_dbh->quote($row[0]); + my $who = $oracle_dbh->quote($row[1]); + my $thetext = $oracle_dbh->quote($row[3]); + my $bug_when = "TO_DATE(" . $oracle_dbh->quote($row[2]) . ", 'YYYY-MM-DD HH24:MI:SS')"; + + $query = "insert into longdescs ( " . + join (', ', @columns) . " ) " . + "values ($bug_id, $who, $bug_when, $thetext)"; + # print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); + print "$count entry added to long descriptions\n"; + $count++; +} + + +# the bugs themselves +my %columns = ( 'bug_id' => '', + 'group_id' => '', + 'assigned_to' => '', + 'bug_file_loc' => '', + 'patch_file_loc' => '', + 'bug_severity' => '', + 'bug_status' => '', + 'view' => '', + 'creation_ts' => '', + 'delta_ts' => '', + 'short_desc' => '', + 'long_desc' => '', + 'op_sys' => '', + 'priority' => '', + 'product' => '', + 'rep_platform' => '', + 'reporter' => '', + 'version' => '', + 'release' => '', + 'component' => '', + 'resolution' => '', + 'class' => '', + 'target_milestone' => '', + 'qa_contact' => '', + 'status_whiteboard' => '', + 'groupset' => '', + 'votes' => ''); + +my @columns_select = keys %columns; +my @oracle_columns; +my $longdesc = ""; + +# all this because Oracle cannot have a column name of 'view' +foreach my $column (@columns_select) { + if ($column eq 'view') { + push (@oracle_columns, 'bug_view'); + } else { + push (@oracle_columns, $column); + } +} + +$query = "select " . join (', ', @columns_select) . " from bugs"; +# print $query . "\n"; +$mysql_sth = $mysql_dbh->prepare($query); +$mysql_sth->execute(); + +$count = 1; +print "\n\n"; + +while (my @row = $mysql_sth->fetchrow_array()) { + my $count = 0; + foreach my $column (@columns_select) { + $columns{$column} = $row[$count]; + $count++; + } + + foreach my $column (@columns_select) { + if (!defined($columns{$column})) { + $columns{$column} = ''; + } + if ($column eq 'delta_ts') { + $columns{$column} = "TO_DATE('$columns{$column}', 'YYYYMMDDHH24MISS')"; + next; + } + if ($column eq 'creation_ts') { + $columns{$column} = "TO_DATE('$columns{$column}', 'YYYY-MM-DD HH24-MI-SS')"; + next; + } + if ($column eq "long_desc") { + $longdesc = $columns{$column}; + $columns{$column} = ":1"; + next; + } + $columns{$column} = $oracle_dbh->quote($columns{$column}); + } + + my @columns_insert; + foreach my $column (@columns_select) { + push (@columns_insert, $columns{$column}); + } + + $query = "insert into bugs ( " . join (', ', @oracle_columns) . " ) " . + "values (" . join (', ', @columns_insert) . " )"; + # print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->bind_param(1, $longdesc, {SQL_LONGVARCHAR => 1 }); + $oracle_sth->execute(); + print "$count entry added to bugs\n"; + $count++; +} + + +# lastly, created the proper sequences +%tables = ( 'bugs' => 'bug_id', + 'logincookies' => 'cookie', + 'attachments' => 'attach_id', + 'products' => 'id', + 'profiles' => 'userid', + 'fielddefs' => 'fieldid'); +foreach my $table (keys %tables) { + eval { + $query = "drop sequence " . $table . "_seq"; + print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); + }; + if ($@) { print "No sequence for $table. Continuing...\n" } + $query = "select max($tables{$table}) from $table"; + print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); + my @result = $oracle_sth->fetchrow_array(); + my $nextval = $result[0] + 1; + $query = "create sequence " . $table . "_seq start with $nextval increment by 1"; + print $query . "\n"; + $oracle_sth = $oracle_dbh->prepare($query); + $oracle_sth->execute(); +} + +print "\n\nAll Done!\n"; + +$mysql_dbh->disconnect(); +$oracle_dbh->disconnect(); + diff --git a/mozilla/webtools/bugzilla/template/bugform_mozilla.tmpl b/mozilla/webtools/bugzilla/template/bugform_mozilla.tmpl new file mode 100644 index 00000000000..dc5dab80086 --- /dev/null +++ b/mozilla/webtools/bugzilla/template/bugform_mozilla.tmpl @@ -0,0 +1,104 @@ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Bug#:[+ $bugform{'id'} +]Platform: + + +[+ $bugform{'platform_popup'} +] + + + Version: + + +[+ $bugform{'version_popup'} +] + + +
Product: + + +[+ $bugform{'product_popup'} +] + + + OS: + + +[+ $bugform{'opsys_popup'} +] + + +
Status:[+ $bug_form{'bug_status'} +]Priority: + + +[+ $bugform{'priority_popup'} +] + + + Cc:[+ $bug_form{'cc_element'} +]
Resolution:[+ $bugform{'resolution'} +]Severity: + + +[+ $bugform{'severity_popup'} +] + + + Component: + + +[+ $bugform{'component_popup'} +] + + +
Assigned To: + [+ $bugform{'assigned_to'} +]
URL: + [+ $bugform{'bugfile_element'} +]
Summary: + [+ $bugform{'summary_element'} +]
Attachments:[+ bugform{'attach_element'} +]
+ + + + + +[+ $bugform{'depends_element'} +] + + + +
+ +
+Additional Comments: +
+
+ diff --git a/mozilla/webtools/bugzilla/template/bugform_redhat.tmpl b/mozilla/webtools/bugzilla/template/bugform_redhat.tmpl new file mode 100644 index 00000000000..b5965af5408 --- /dev/null +++ b/mozilla/webtools/bugzilla/template/bugform_redhat.tmpl @@ -0,0 +1,190 @@ + + + + + + + + + + + + + + + + + + +
Product - VersionComponentStatusShort Summary
[+ $::bug_form{'product'} +] - [+ $::bug_form{'version'} +][+ $::bug_form{'component'} +][+ $::bug_form{'bug_status'} +][+ $::bug_form{'short_desc'} +]
+ +

+ + + + + + +
Opened by [+ $::bug_form{'reporter'} +] + on  [+ $::bug_form{'creation_ts'} +]   Long Description
+
+
+[+ $::bug_form{'description'} +]
+
+
+        
+ +

+ + + + + + + + + + +
Additional Information
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
Bug#:[+ $::bug_form{'bug_id'} +]Product: + + +[+ $::bug_form{'product_popup'} +] + + +Version: + + +[+ $::bug_form{'version_popup'} +] + + +
Platform: + + +[+ $::bug_form{'platform_popup'} +] + + +Reporter:[+ $::bug_form{'reporter'} +] + + +[+ $::bug_form{'component_popup'} +] + + +
Status:[+ $::bug_form{'bug_status'} +]Priority: + + +[+ $::bug_form{'priority_popup'} +] + + +
Resolution:[+ $::bug_form{'resolution'} +]Severity: + + +[+ $::bug_form{'sev_popup'} +] + + +
Assigned To:[+ $::bug_form{'assigned_to'} +] Component Text:[+ $::bug_form{'component_text'} +]
+

+ + + + + + [+ $::bug_form{'qacontact_element'} +] + [+ $::bug_form{'url_element'} +] + [+ $::bug_form{'summary_element'} +] + [+ $::bug_form{'status_whiteboard'} +] + + + + +
Cc:[+ $::bug_form{'cc_element'} +]
Attachments: + + + + +
[+ $::bug_form{'attachment_element'} +]
+
+ +

+ + +[+ $::bug_form{'depends_element'} +] + + +

Additional Comments
+ +

+ + + + + +
+ + +[+ $::bug_form{'resolution_change'} +] + + + + + +[+ $::bug_form{'group_change'} +] + + +
+ +

+ + + + +
+ + +[+ $::bug_form{'commit_change'} +] + + +
+ + + + +

+
+ +[View Bug Activity]   +[Format For Printing] + +
+

+


+

diff --git a/mozilla/webtools/bugzilla/template/contract_redhat.tmpl b/mozilla/webtools/bugzilla/template/contract_redhat.tmpl new file mode 100644 index 00000000000..0597ac9d1c4 --- /dev/null +++ b/mozilla/webtools/bugzilla/template/contract_redhat.tmpl @@ -0,0 +1,10 @@ + + + + +
+ Attention: I have [+ $contract_form{'count'} +] + bug(s) that are marked as contract priority. + Take me to this [+ $contract_form{'link'} +] list. +
+ diff --git a/mozilla/webtools/bugzilla/template/footer_mozilla.tmpl b/mozilla/webtools/bugzilla/template/footer_mozilla.tmpl new file mode 100644 index 00000000000..18fbc73e271 --- /dev/null +++ b/mozilla/webtools/bugzilla/template/footer_mozilla.tmpl @@ -0,0 +1,29 @@ +

+ + + + +
+ + + + + +
+ [Home]   + [New Bug]   + [Query Bugs]   + [Help]   + [LogOut]   + [Errata] +
+
For questions or comments on bugzilla send mail to + bugzilla-owner@redhat.com
+
This is Bugzilla: the Mozilla bug system. For more + information about what Bugzilla is and what it can do, see + mozilla.org’s + bug pages
+
+
+ + diff --git a/mozilla/webtools/bugzilla/template/footer_redhat.tmpl b/mozilla/webtools/bugzilla/template/footer_redhat.tmpl new file mode 100644 index 00000000000..dcf9f8af0ec --- /dev/null +++ b/mozilla/webtools/bugzilla/template/footer_redhat.tmpl @@ -0,0 +1,29 @@ +

+ + + + +
+ + + + + +
+ [Home]   + [New Bug]   + [Query Bugs]   + [Help]   + [LogOut]   + [Errata] +
+
For questions or comments on bugzilla send mail to + bugzilla-owner@redhat.com
+
This is Bugzilla: the Mozilla bug system. For more + information about what Bugzilla is and what it can do, see + mozilla.org’s + bug pages
+
+
+ + diff --git a/mozilla/webtools/bugzilla/template/header_mozilla.tmpl b/mozilla/webtools/bugzilla/template/header_mozilla.tmpl new file mode 100644 index 00000000000..95e517b446c --- /dev/null +++ b/mozilla/webtools/bugzilla/template/header_mozilla.tmpl @@ -0,0 +1,45 @@ + +[+ $title +] + + + + + + + + + + + + +
+ + logo + + redhat.com + logo + + Develzilla + + + bug #
+  [+ $header +] + + + + + + +
+ + [+ $login +] + + + + [+ $navigation +] + +
+
+

+ diff --git a/mozilla/webtools/bugzilla/template/header_redhat.tmpl b/mozilla/webtools/bugzilla/template/header_redhat.tmpl new file mode 100644 index 00000000000..4d3b286a34a --- /dev/null +++ b/mozilla/webtools/bugzilla/template/header_redhat.tmpl @@ -0,0 +1,45 @@ + +[+ $title +] + + + + + + + + + + + + +
+ + logo + + redhat.com + logo + + Develzilla + +
+ bug #
+  [+ $header +] + + + + + + +
+ + [+ $login +] + + + + [+ $navigation +] + +
+
+

+ diff --git a/mozilla/webtools/bugzilla/template/index_mozilla.tmpl b/mozilla/webtools/bugzilla/template/index_mozilla.tmpl new file mode 100644 index 00000000000..7ac8eb0b616 --- /dev/null +++ b/mozilla/webtools/bugzilla/template/index_mozilla.tmpl @@ -0,0 +1,77 @@ + + + + + + +
+ + + + + +
+ + Main Page + +
+ + + +
+ +
+ + This is Bugzilla: the Mozilla bug system. For more + information about what Bugzilla is and what it can do, see + mozilla.org's + bug pages. +
+ + + + + +This is where we put in lots of nifty words explaining all about +bugzilla. + +

+ +But it all boils down to a choice of: +
+Query existing bug reports
+Enter a new bug report
+Get summary reports
+

+Open a new Bugzilla account
+Forget the currently stored login
+Change password or user preferences
+

+ bug #
+ + + + diff --git a/mozilla/webtools/bugzilla/template/index_redhat.tmpl b/mozilla/webtools/bugzilla/template/index_redhat.tmpl new file mode 100644 index 00000000000..cd8c6c3481c --- /dev/null +++ b/mozilla/webtools/bugzilla/template/index_redhat.tmpl @@ -0,0 +1,62 @@ + + + + + +
+ + + + + +
Bug Options
+ Query existing bug reports
+ Enter a new bug report
+ Get summary reports
+
+

+ + + + + + +
Member Options
+ Open a new Bugzilla account
+ Forget the currently stored login
+ Change password or user preferences
+
+

+ + + + +
+ Statistics for this web-site can be found here. +
+

+ +
+ +

+ + + + + + + + +
Tools Provided By
+ + + + + + + + +
+
If you are interested in downloading this version of Bugzilla, you can from + here.
+ diff --git a/mozilla/webtools/bugzilla/template/query_mozilla.tmpl b/mozilla/webtools/bugzilla/template/query_mozilla.tmpl new file mode 100644 index 00000000000..58f5cce0160 --- /dev/null +++ b/mozilla/webtools/bugzilla/template/query_mozilla.tmpl @@ -0,0 +1,216 @@ + +[+ $query_form{'javascript'} +] + + +

+ + + + + + + + + + + + + + + + + + +
Status:Resolution:Platform:OpSys:Priority:Severity:
+ + +[+ $query_form{'status_popup'} +] + + + + + +[+ $query_form{'resolution_popup'} +] + + + + + +[+ $query_form{'platform_popup'} +] + + + + + +[+ $query_form{'opsys_popup'} +] + + + + + +[+ $query_form{'priority_popup'} +] + + + + + +[+ $query_form{'severity_popup'} +] + + +
+ +

+ + + + + + + + + + + + +
+ + +[+ $query_form{'emailinput1'} +] +

+[+ $query_form{'emailinput2'} +] + + +

+ + +[+ $query_form{'bugidtype_popup'} +] +bugs numbered: +[+ $query_form{'bugidtype_element'} +] + + +
+ Changed in the last days. + + At least votes. +
+ + + + + + + + + + + +
Where the field(s) + + + +[+ $query_form{'chfield_popup'} +] + + + + changed. + + dates + to +
changed to value (optional) +
+ +

+ + + + + + + + + + + + +
Program:Version:Component:
+ + +[+ $query_form{'product_popup'} +] + + + + + +[+ $query_form{'version_popup'} +] + + + + + +[+ $query_form{'component_popup'} +] + + +
+ + + + +[+ $query_form{'summary_popup'} +] + + + +[+ $query_form{'description_popup'} +] + + + +[+ $query_form{'bugfile_popup'} +] + + +
+ +

+ +


+ + + + +
+ + +[+ $query_form{'chart_popup'} +] + + +
+
+ + +[+ $query_form{'query_popup'} +] + + +Sort By: + + +[+ $query_form{'order_popup'} +] + + + + + + +
+

Give me a clue about how to use this form. +

+ + +[+ $query_form{'admin_menu'} +] + + +Change your password or preferences.
+Create a new bug.
+Open a new Bugzilla account
+Bug reports
+ + + + diff --git a/mozilla/webtools/bugzilla/template/query_redhat.tmpl b/mozilla/webtools/bugzilla/template/query_redhat.tmpl new file mode 100644 index 00000000000..0f21770efcd --- /dev/null +++ b/mozilla/webtools/bugzilla/template/query_redhat.tmpl @@ -0,0 +1,322 @@ + + +[+ $query_form{'javascript'} +] + + + +[+ + if (!defined($::COOKIE{'Bugzilla_login'})) { + $OUT = "

You are currently not logged in. You may want to " . + "login to use more " . + "options such as stored queries or to make changes.
"; + } ++] + +
+ + + + + +
Product Information
+ + + + + + + + + + + + + +
ProgramVersionComponent
+ + +[+ $query_form{'product_popup'} +] + + + + + +[+ $query_form{'version_popup'} +] + + + + + +[+ $query_form{'component_popup'} +] + + +
All Components Except Selected
+
+ +

+ + + + + + +
Bug State, Class, and Platform Information
+ + + + + + + + [+ $query_form{'targetmilestone_header'} +] + + + + + + + + +
StatusResolutionPlatformPrioritySeverity
+ + +[+ $query_form{'status_popup'} +] + + + + + +[+ $query_form{'resolution_popup'} +] + + + + + +[+ $query_form{'platform_popup'} +] + + + + + +[+ $query_form{'priority_popup'} +] + + + + + +[+ $query_form{'severity_popup'} +] + + + + + +[+ $query_form{'targetmilestone_popup'} +] + + +
+
+ +

+ + + + + + +
Email Information
+ + + + +
+ + + +
+ + + + + + + + + + +
Email: +  matching as + + + Assigned To +
+ Reporter +
(Will match any of the selected fields) + CC    +
+
+

+

+ + + +
+ + + + + + + + + + +
Email: +  matching as + + + Assigned To +
+ Reporter +
(Will match any of the selected fields) + CC    +
+
+

+

+
+ +

+ + + + + + +
Time Information
+ + + + +
+ Changed in the last days. +
+ + + + + + + + + +
Where the field(s) + + +[+ $query_form{'chfield_popup'} +] + + + changed. + dates + to +
changed to value (optional) +
+
+ +

+ + + + + + +
Text Information
+ + + + +[+ $query_form{'summary_element'} +] + + + + + +[+ $query_form{'longdesc_element'} +] + + + + + +[+ $query_form{'bugfile_element'} +] + + + + + +[+ $query_form{'whiteboard_element'} +] + + +
+
+ +

+ + + + + + +
Query Actions
+ + +[+ $query_form{'query_element'} +] + + + Sort By: + + +[+ $query_form{'order_popup'} +] + + + + + + + +
+ +

+ + + + + + +
Bugzilla Options
+ Give me a clue about how to use this form.

+ + +[+ $query_form{'admin_menu'} +] + + +

+ +[+ + if (defined($::COOKIE{'Bugzilla_login'})) { + $OUT = "Log in as someone besides $::COOKIE{'Bugzilla_login'} or log out.
"; + $OUT = "Change your password or preferences.
"; + } ++] + + Open a new Bugzilla account
+ Bug reports
+

+

+