The Address Book

You need to get a couple of pieces of infrastructure in place before moving on to order checkout. One major piece of dangling functionality involves the wallet and the address book.

The wallet (the list of credit cards) will need to use addresses. As you recall way back in the ERD design, you used the Address object as a property of the credit card rather than recording address information separately in the credit card itself. As a result, you should get addresses working first.

To begin, you need several new queries in your properties file. To remind you, the schema for ADDRESS in the database is as follows:

 create table ADDRESS ( ADDRESS_ID int not null auto_increment, FIRST_NAME char(30) not null, LAST_NAME char(40) not null, ...

Get MySQL™ and JSP™ Web Applications: Data-Driven Programming Using Tomcat and MySQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.