Errata

Java Programming with Oracle SQLJ

Errata for Java Programming with Oracle SQLJ

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.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.

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

Version Location Description Submitted by Date submitted
Printed Page 26
Middle of page

I am not sure if this is an actual error in the code or rather an error in my
configuration of Oracle 9i 9.2.0.1.0 but basically the
sql statment to create the products table give me an ORA-02253 error stating that
constraint specification not allowed here and refrencing the following line as that
which has caused the error:

CONSTRAINT products_fk_product_types

To put this in context the actual sql create statment is:

create table products (
id number constraint products_pk primary key,
type_id number constraint products_fk_product_types
refrence product_types(id),
name varchar2(50), not null,
description varchar2(500),
price number(10, 2));

Anonymous   
Printed Page 94
4th line from the end: The UPDATE statement:, in the "update_product_procedure"

procedure code/listing.;
(August 2001 Edition)

The UPDATE statement is missing a WHERE clause . Without that clause, all the product
prices will be updated without exeption (unless the "id" did not exist in the first
place).

The statement should be as followed:

-- if the product does exist then perform the update
UPDATE products SET price = price * p_factor WHERE id = p_product_id;

Anonymous   
Printed Page 304
2nd code fragment, last code line on page

parameter_declartion ::=

'declaration'

Anonymous