Closed Bug 276634 Opened 20 years ago Closed 20 years ago

Devguide update reflecting change in DB.pm deprecated routines.

Categories

(Bugzilla :: bugzilla.org, defect)

2.19.1
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: kbenton, Assigned: kbenton)

Details

Attachments

(1 file, 5 obsolete files)

Current developer's guide still suggests using deprecated routines.  This is
inappropriate.
Attachment #170003 - Flags: review?
Comment on attachment 170003 [details] [diff] [review]
Diff to developer's guide web page.

+    <p><code class="perl">$Query="SELECT field1 FROM table WHERE field2 = " .
SqlQuote($variable);</code></p>

I'd prefer to have a space before and after the = sign. Also, $Query should
probably start with a lowercase q.

+  my $dbh = Bugzilla->dbh; # Connects if not already connected.<br>
+ 
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&
nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;# Also handles
db, user, password...<br>
+  my $sth = $dbh->prepare("SELECT foo, bar FROM bath WHERE log = ?");<br>

I hate having this little hack with &nbsp;. If <code> doesn't show spaces,
maybe <pre> will.

Anyway, in this case, I'd prefer to have the comment and the line of code on
different lines, especially since the code is followed up on the next line.
Attachment #170003 - Flags: review? → review-
Assignee: documentation → kevin.benton
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows XP → All
Hardware: PC → All
s/the code is followed up/the comment is followed up/

(in my previous comment)
Component: Documentation → bugzilla.org
Made the changes you requested, Vlad.
Attachment #170003 - Attachment is obsolete: true
Attachment #171572 - Flags: review?
Attachment #171572 - Attachment is obsolete: true
Attachment #171576 - Flags: review?
Comment on attachment 171572 [details] [diff] [review]
Updated devguide update reflecting change in DB.pm deprecated routines.

Left out a change.
Attachment #171572 - Flags: review?
Status: NEW → ASSIGNED
Component: bugzilla.org → Documentation
Attachment #171576 - Flags: review? → review?(documentation)
Comment on attachment 171576 [details] [diff] [review]
One more change I missed - $Query -> $query

One more change...
Attachment #171576 - Attachment is obsolete: true
Attachment #171576 - Flags: review?(documentation)
Attachment #173883 - Flags: review?(documentation)
Comment on attachment 173883 [details] [diff] [review]
Last change I hope - added missing noun

Not last change, sorry...

We also talked about how this (pseudo)code was incorrect;

while ($result=$sth->fetchrow_array()) {

That needs to be fixed up to get an r+ from me. 


+<p>For more information, see the DBI pod or see the embedded documentation in
Bugzilla/DB.pm.</p>

Nit: *consult* the DBI pod, or see the ...

(Having 'see the' twice in a row grates on me, but it's only nit-level.)
Attachment #173883 - Flags: review?(documentation) → review-
Attachment #173883 - Attachment is obsolete: true
Attachment #173971 - Flags: review?(documentation)
Attachment #173971 - Flags: review?(documentation)
Attachment #173972 - Flags: review?(documentation)
Attachment #173972 - Flags: review?(documentation) → review+
Looks like patch was applied by Travis.  Thanks :)
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Component: Documentation → bugzilla.org
QA Contact: matty_is_a_geek → default-qa
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: