Design Notes

Dynamic-CD Example - Shopping Cart - List all items

Shopping Cart home page


CategoryParts available
Books Harry Potter 5 - hardback (SC_BK_001) 12.99 More info
Harry Potter 5 - paperback (SC_BK_002) 5.99
Stephen Queen Omnibus (SC_BK_003) 15.99
David Splodge's Cookery Classics (SC_BK_004) 9.99
Clapham Omnibus Gender Statistics 2000 (SC_BK_005) 19.99
Cobol to Perl Porting Manual (SC_BK_006) 39.99
CDs 2001 Classic Pop Compilation (SC_CD_001) 5.00
String Quartet all time Top 10 (SC_CD_002) 9.90
Forgotten Genres - Vol 2 (SC_CD_003) 9.99
Earth tranquility harmonies (SC_CD_004) 14.99
Trivia Earth tranquilities mouse mat (SC_TV_001) 3.99 More info
Heat seeking fly swatter (SC_TV_002) 39.99
Bonsai Redwood (SC_TV_003) 19.99
Transporter unit - 100 mile range (SC_TV_004) 199.99 More info
Transporter unit - 1000 mile range (SC_TV_005) 399.99
Mobile phone base station (SC_TV_006) 1999.99 More info

Design Notes
To see the ASP source for this page click here
This page illustrates a simple look up of information in a database.

Two nested database queries are used.  The first query retrieves all the information in the Categories table, sorted by the Order field.  As each category is found, a second query finds all parts in that category: the Category ID field in the Parts table must match the current Categories ID.

If there is any more information for a part, a link to moreinfo.asp is generated, passing the Parts ID as a "QueryString" parameter in the URL, eg moreinfo.asp?id=12.