How the Scheduled Tours Tree View Was Defined

Previous Next

To define the Scheduled Tours tree view, these steps were taken:

1. In the Property Inspector, select the Tree View 1 object (the Tree View, not the Tree View Node or the Tab Page).
2. The tree view already contains one Tree View Node. You need two more. Open the Controls tab page of the cataloge, move the mouse over the icons until the status bar says "Tree View Node", and then drag-and-drop two Tree View Nodes from the Controls tab page onto the design view.
3. Using the Object tree, verify that the tree view now has 3 tree view nodes.
4. For Tree View Node 1, set Child Nodes to Tree View Node 2.

For Tree View Node 2, set Child Nodes to Tree View Node 3.

Save your work so far.

5. Define the application data that the catalog is going to retrieve and display.

For Tree View Node 1, set SQL Query to:

SELECT   DISTINCT destination

FROM     tour

6. For Tree View Node 2, set SQL Query to:

SELECT  tour_type,destination

FROM    tour

WHERE   destination=:DESTINATION

NOTE:

Only the TOUR_TYPE column, the first selected column, is shown in the tree. The DESTINATION column will be used in the SQL Query of Tree View Node 3.

7. For Tree View Node 3, set SQL Query to:

SELECT  TO_CHAR(start_date,'YYYY/MM DD Day'),schedtour_id,max_part

FROM    schedtour

WHERE   destination    = :DESTINATION

AND     tour_type     = :TOUR_TYPE