Download presentation
Presentation is loading. Please wait.
1
A Guide to Oracle9i1 Advanced Forms Builder Topics Chapter 10
2
A Guide to Oracle9i2 Objectives Learn about form items that display boilerplate items, calculated data, and images Create forms that allow users to load and display image data Create form lists that display static data values Learn how to configure forms that retrieve and manipulate large data sets Understand how to control data block relationships
3
A Guide to Oracle9i3 Creating Non-Input Form Items Most form items (text items, radio groups, check boxes, and so forth) allow users to input and change data values Forms Builder also supports a number of items that display data but do not allow the user to change the displayed value
4
A Guide to Oracle9i4 Creating Non-Input Form Items
5
A Guide to Oracle9i5 Creating Non-Input Form Items Display items: display text data that the user cannot modify; can also display calculated values based on form data values Boilerplate objects (text and shapes) placed on top of other boilerplate objects, appear in the order in which you create them
6
A Guide to Oracle9i6 Creating Non-Input Form Items Following data block form displays data from the Clearwater Traders INVENTORY database table Display items on this form include: –One that shows value for each inventory item, calculated as price times quantity on hand –Summary display item sums values of all retrieved items –Boilerplate rectangle and text label describe and emphasize the summary display item
7
A Guide to Oracle9i7 Creating Non-Input Form Items
8
A Guide to Oracle9i8 Creating a Form to Load and Display Graphic Images Display graphic image on form as static imported image, which incorporates image data into form design (.fmb) file and compiles it into.fmx file, or as a dynamic image, which loads image data from workstation file system into form at runtime Use static imported images to add graphic enhancements that stay the same regardless of data that currently appears on form
9
A Guide to Oracle9i9 Creating a Form to Load and Display Graphic Images Use dynamic images to display images retrieved from database or file system while form is running, or to retrieve and display large static images that do not appear every time you run form To create a form that loads and displays dynamic images that the database stores, base form on table that contains data field with BLOB data type To load images into database, create form trigger that uses READ_IMAGE_FILE built-in to load the image into form image item
10
A Guide to Oracle9i10 Creating a Form to Load and Display Graphic Images
11
A Guide to Oracle9i11 Creating the Data Block and Layout Use the Data Block and Layout Wizards to create the data block and layout for the ITEM table fields Recall that the ITEM table has a field named ITEM_IMAGE that is a BLOB (binary large object) data type, and that this field currently contains a locator for the BLOB image
12
A Guide to Oracle9i12 Creating the Data Block and Layout
13
A Guide to Oracle9i13 Creating Static Lists in Forms A list item is a data block item that displays a static list from which users can select to provide form inputs Use a form list item when the user can select from a limited number of choices that do not change very often Use lists instead of radio buttons when there are more than five choices or when there is a limited amount of space on the form to display radio buttons
14
A Guide to Oracle9i14 Three Types of Static List Items Poplist: drop-down list that user opens when needed. When user opens list, drop-down box displays up to 10 items at once T-List: also called Text List, always displays the current selection. It has up and down scroll arrows on right edge, and user can use these arrows to scroll through list items sequentially and select different values Combo box: Poplist in which user can enter value if desired value does not appear in list
15
A Guide to Oracle9i15 Creating Static Lists in Forms
16
A Guide to Oracle9i16 Creating Static Lists In Forms
17
A Guide to Oracle9i17 Creating Static Lists in Forms
18
A Guide to Oracle9i18 Creating Static Lists in Forms
19
A Guide to Oracle9i19 Using Forms with Large Data Sets Form developers need to estimate the maximum number of records that form queries might retrieve, and then design their form applications to ensure that form performance remains satisfactory
20
A Guide to Oracle9i20 Using Forms with Large Data Sets Approaches for improving form data retrieval performance include –creating indexes on search fields –training users to count query hits –forcing users to enter search conditions in forms that might retrieve large data sets –configuring LOVs to allow users to filter data
21
A Guide to Oracle9i21 Improving Form Data Retrieval
22
A Guide to Oracle9i22 Improving Form Data Retrieval
23
A Guide to Oracle9i23 Improving Form Data Retrieval
24
A Guide to Oracle9i24 Improving Form Data Retrieval
25
A Guide to Oracle9i25 Controlling Data Block Master-Detail Relationships In a master-detail form, master block and detail block are coordinated Master record and detail record are associated by a relationship coordination-causing event: any operation that causes current record in master block to change, When user performs a coordination-causing event, detail block values also change
26
A Guide to Oracle9i26 Controlling Data Block Master-Detail Relationships
27
A Guide to Oracle9i27 Controlling Data Block Master-Detail Relationships When you use the Data Block Wizard to create a form that displays a master-detail relationship between two blocks, Forms Builder automatically –creates a relation object in the master block –creates several triggers and PL/SQL program units that enforce coordination between the form master and detail blocks
28
A Guide to Oracle9i28 Controlling Data Block Master-Detail Relationships The relation object specifies properties about the relationship: –name of the detail block –SQL join condition that specifies the relationship between the master block and the detail block and how the form handles deletions of master block records
29
A Guide to Oracle9i29 Controlling Data Block Master-Detail Relationships
30
A Guide to Oracle9i30 Relation Triggers and Program Units
31
A Guide to Oracle9i31 Controlling Data Block Master-Detail Relationships Relation ’ s Delete Record Behavior property specifies how deleting a record in master block affects records in detail block Possible values: –Non Isolated: prevents user from deleting master record when associated detail records exist in database –Isolated: allows user to delete master record when associated detail records exist –Cascading: performs cascading delete; form deletes the master record, then deletes all associated detail records in detail block ’ s base table
32
A Guide to Oracle9i32 Controlling Data Block Master-Detail Relationships A relation ’ s Prevent Masterless Operations property specifies whether users can query or insert detail block records when there is no master record in the master block
33
A Guide to Oracle9i33 Controlling Data Block Master-Detail Relationships A relation ’ s Deferred and Automatic Query properties work together to determine whether the detail block records automatically change when the user selects a new master record, or if the user has to navigate explicitly to the detail block and refresh the detail records
34
A Guide to Oracle9i34 Relation Triggers and Program Units These program units are called by the relation-handling triggers or by one another, and handle the details of the master-detail processing
35
A Guide to Oracle9i35 Relation Triggers and Program Units
36
A Guide to Oracle9i36 Changing Relation Properties Dynamically User can specify retrieval properties of a relation while form is running Use the SET_RELATION_PROPERTY built- in, which has the following syntax: SET_RELATION_PROPERTY('relation_name', property, value);
37
A Guide to Oracle9i37 Changing Relation Properties Dynamically
38
A Guide to Oracle9i38 Changing Relation Properties Dynamically
39
A Guide to Oracle9i39 Summary Creating Non-input form items –Display items Creating forms to load and display graphic images Creating the data block and layout Creating static lists –Types of static lists Using forms with large data sets –Improving form data retrieval Controlling data block master-detail relationships –Relation triggers and program units Changing relation properties dynamically
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.