In real life, there would rarely be any (Web hosting)

In real life, there would rarely be any need to open a view from Database Explorer and see the records it returns, because the way the results are shown in Database Explorer aren t especially pretty or easy to read. Instead normally you d use the view to extract data from your tables via databound controls in the Web pages you create. Each data-bound control can choose as much (or as little) information from the view as it needs. For example, one control could display a list of all users who purchased a specific item. Another could list all items purchased by a specific user. Still other controls could organize information from the view in other ways. Creating a Table of Pictures Not all database tables need to be linked to other tables. You can use a database table to store things that don t relate directly to specific users or specific items. For example, if you have pictures you want to show or allow people to download, you can create a table of pictures. Then, as you ll see in Chapter 12, you can use Data controls to make it easy to display multiple pictures on a page. You don t need to put the pictures directly in the database. Rather, you can store all the pictures in a folder (or multiple folders). Then just create a table that identifies the picture s location within your site. As an example, Figure 11-33 shows where I ve created a subfolder named FlowerPix within my Images folder in Solution explorer. Each of the filenames, Flower02,jpg, Flower02.jpg, and so forth, is a photo of a flower. Figure 11-33: The FlowerPix folder contains ten pictures of flowers. 254 Part III: Personalization and Databases
Searching for affordable and proven webhost to host and run your servlet applications? Go to Linux Web Hosting services and you will find it.

Leave a Reply