Closed
Bug 285552
Opened 21 years ago
Closed 21 years ago
Cannot enter a bug on PostgreSQL
Categories
(Bugzilla :: Bugzilla-General, defect, P1)
Tracking
()
RESOLVED
FIXED
Bugzilla 2.20
People
(Reporter: mkanat, Assigned: mkanat)
References
Details
Attachments
(1 file, 1 obsolete file)
661 bytes,
patch
|
Tomas.Kopal
:
review+
|
Details | Diff | Splinter Review |
The SQL for entering a bug in post_bug.cgi cannot run on PostgreSQL, mostly
because of null-condition failures. (That is, a column is NOT NULL but we don't
insert something into it.)
![]() |
Assignee | |
Comment 1•21 years ago
|
||
This doesn't allow me to run post_bug all the way through, but it does allow
the bug to get into the DB.
Attachment #176982 -
Flags: review?(Tomas.Kopal)
![]() |
Assignee | |
Updated•21 years ago
|
Priority: -- → P1
Target Milestone: --- → Bugzilla 2.20
![]() |
Assignee | |
Updated•21 years ago
|
Status: NEW → ASSIGNED
Comment 2•21 years ago
|
||
Comment on attachment 176982 [details] [diff] [review]
Fixes for post_bug.cgi
>Index: post_bug.cgi
>===================================================================
>RCS file: /cvsroot/mozilla/webtools/bugzilla/post_bug.cgi,v
>retrieving revision 1.105
>diff -u -r1.105 post_bug.cgi
>--- post_bug.cgi 7 Mar 2005 21:34:45 -0000 1.105
>+++ post_bug.cgi 10 Mar 2005 06:57:23 -0000
>@@ -335,7 +335,8 @@
> # Build up SQL string to add bug.
> my $sql = "INSERT INTO bugs " .
> "(" . join(",", @used_fields) . ", reporter, creation_ts, delta_ts, " .
>- "estimated_time, remaining_time, deadline) " .
>+ "estimated_time, remaining_time, deadline" .
>+ ",resolution, status_whiteboard, votes, keywords, lastdiffed) " .
> "VALUES (";
Hmmm, I am almost sure that at least keywords can be specified in the bug, and
then you would be setting it twice (which I guess results in SQL error). Can we
somehow check if it is specified in the form? (e.g. if (grep (/keywords/,
@used_fields) or something like that?
Or we can add default value to the schema, but that's not so generic (if
someone modifies the enter bug form to specify initial status_whiteboard, we
are screwed again), so only if there is no other way :-).
Attachment #176982 -
Flags: review?(Tomas.Kopal) → review-
![]() |
Assignee | |
Comment 3•21 years ago
|
||
OK, I think that status_whiteboard and keywords should both have a default in
the schema.
![]() |
Assignee | |
Comment 4•21 years ago
|
||
OK, here's the last fix that's not a part of the blockers.
Attachment #176982 -
Attachment is obsolete: true
Attachment #177106 -
Flags: review?(Tomas.Kopal)
Comment 5•21 years ago
|
||
Comment on attachment 177106 [details] [diff] [review]
Last remaining fix
Can a patch be simpler than this? :-)
Attachment #177106 -
Flags: review?(Tomas.Kopal) → review+
![]() |
Assignee | |
Updated•21 years ago
|
Flags: approval?
Updated•21 years ago
|
Flags: approval? → approval+
![]() |
||
Comment 6•21 years ago
|
||
(In reply to comment #5)
> Can a patch be simpler than this? :-)
Yes, it can. I don't think anyone's ever going to beat this one:
https://bugzilla.mozilla.org/show_bug.cgi?id=150901#c4
:-)
![]() |
Assignee | |
Comment 7•21 years ago
|
||
Checking in post_bug.cgi;
/cvsroot/mozilla/webtools/bugzilla/post_bug.cgi,v <-- post_bug.cgi
new revision: 1.108; previous revision: 1.107
done
Status: ASSIGNED → RESOLVED
Closed: 21 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•