Demonstration
Introduction
Start RADpage
RADpage
Databases
    My Database Table
    Record Display
    Database Form
    My Database Form
    Formatted Table
    Text View
    Constraints
    Scroller
    Unique Search
    Search
Shopping
Programming
Use RADpage
    

Listing Records from the Database in Table Format

On this page we show you how to query the database and display the results in a formatted table at the bottom of this Web page. In fact we show you how to create a database table (as on the Databases page) from scratch.

In the RADpage window, click on Insert, then database and select dbdisplay (Documentation). Select guestbook as relation and enter 20 as the maximum number of records. Then click one of the blue Component Handles on this page to indicate where you want the new component to appear.

You can also control which fields you want to see displayed. First click on the blue Component Handle which marks the beginning of the dbdisplay component. This will load the dbdisplay object into the RADpage window. Once it appears in the RADpage window, click on the Fields link. Then select the fields you want shown (e.g. Guest_Name, Email) and press save. Your changes will automatically appear in the updated Browser window (this page).

The table should work fine now. You can now add a dbselectlink column that creates a link to the record display. Select the dbformat component and then click on dbselectlink. The dbselectlink needs the following parameters: href must point to the dbcont.hei page. Action must be display and receiver dbcontainer1 and key field Guest_Name. (Documentation).

Finally, you can restore this page to its original condition by once again clicking on the dbdisplay component (to load it into the RADpage window) and clicking on the "Delete" button. Try it and see.

(Documentation)  Next


Created using RADpage web components
© 1996-2012 H.E.I. All Rights Reserved.