Errata

Oracle PL/SQL Best Practices

Errata for Oracle PL/SQL Best Practices

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released. If the error was corrected in a later version or reprint the date of the correction will be displayed in the column titled "Date Corrected".

The following errata were submitted by our customers and approved as valid errors by the author or editor.

Color key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted By Date submitted Date corrected
PDF
Page 111
2nd paragraph

I think the package is "FORMAT_ERROR_BACKTRACE", in the index occurrs the same.

"DBMS_UTILITY.FORMAT_BACK_TRACE
Starting with Oracle Database 10g Release 2, use DBMS_UTILITY.FORMAT_
BACK_TRACE to obtain the line number on which the most recent exception
was raised. This is a critical piece of information, long missing in PL/"

Note from the Author or Editor:
Yes, this person is right. Any reference in the entire book to

DBMS_UTILITY.FORMAT_BACK_TRACE

should be changed to

DBMS_UTILITY.FORMAT_ERROR_BACKTRACE

juan alberto rodriguez villena  Mar 24, 2011 
Printed
Page 168
1st paragraph

UPDATE book
SET author = 'FEUERSTEIN, STEVEN'
WHERE author = 'FEVERSTEIN, STEPHEN'
RETURNING l_count_modified;

PL/SQL: ORA-00925: missing INTO keyword

Note from the Author or Editor:
Wow. This is a bit nasty. On page 168, everything from "Alternatively, you can..." to the end of the section should be REMOVED. It actually doesn't make any sense.

Anonymous  Oct 08, 2008 
Printed
Page 93
The PL/SQL Code started in previous page

The PL/SQL Function "fine" causes an implicit casting from NUMBER to INTEGER. Although the business rule in the example defined to allow any value between $.05 and $.25. The function just truncates the value.

Note from the Author or Editor:
The 6th line from the top of 93 should change to:

RETURN NUMBER;

Anonymous  Aug 20, 2008 
Printed
Page 82
PL/SQL code on page

c_hired_more_than_a_year CONSTANT BOOLEAN := MONTHS_BETWEEN (emp_rec.hire_date, sysdate) > 10 statement should be replaced with
c_hired_more_than_a_year CONSTANT BOOLEAN := MONTHS_BETWEEN (sysdate, emp_rec.hire_date) > 10.

Otherwise months_between generates minus values.

Note from the Author or Editor:
I agree. Change this:

c_hired_more_than_a_year CONSTANT BOOLEAN := MONTHS_BETWEEN (emp_rec.hire_date, sysdate) > 10;

to this:

c_hired_more_than_a_year CONSTANT BOOLEAN := MONTHS_BETWEEN (sysdate, emp_rec.hire_date) > 10;

Anonymous  Aug 20, 2008 
Printed
Page 83
sample code at bottom of page

1_title_length PLS_INTEGER
should be:
1_page_length PLS_INTEGER

Anonymous