beginning oracle application express 5
TRANSCRIPT
Beginning Oracle Application Express 5
Doug Gault
Beginning Oracle Application Express 5
Copyright © 2015 by Doug Gault
This work is subject to copyright. All rights are reserved by the Publisher, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or hereafter developed. Exempted from this legal reservation are brief excerpts in connection with reviews or scholarly analysis or material supplied specifically for the purpose of being entered and executed on a computer system, for exclusive use by the purchaser of the work. Duplication of this publication or parts thereof is permitted only under the provisions of the Copyright Law of the Publisher’s location, in its current version, and permission for use must always be obtained from Springer. Permissions for use may be obtained through RightsLink at the Copyright Clearance Center. Violations are liable to prosecution under the respective Copyright Law.
ISBN-13 (pbk): 978-1-4842-0467-2
ISBN-13 (electronic): 978-1-4842-0466-5
Trademarked names, logos, and images may appear in this book. Rather than use a trademark symbol with every occurrence of a trademarked name, logo, or image we use the names, logos, and images only in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark.
The use in this publication of trade names, trademarks, service marks, and similar terms, even if they are not identified as such, is not to be taken as an expression of opinion as to whether or not they are subject to proprietary rights.
While the advice and information in this book are believed to be true and accurate at the date of publication, neither the authors nor the editors nor the publisher can accept any legal responsibility for any errors or omissions that may be made. The publisher makes no warranty, express or implied, with respect to the material contained herein.
Managing Director: Welmoed Spahr Lead Editor: Jonathan GennickTechnical Reviewer: Warren CappsEditorial Board: Steve Anglin, Louise Corrigan, Jonathan Gennick, Robert Hutchinson,
Michelle Lowman, James Markham, Matthew Moodie, Jeffrey Pepper, Douglas Pundick, Ben Renow-Clarke, Gwenan Spearing
Coordinating Editor: Jill Balzano Copy Editor: April RondeauCompositor: SPi GlobalIndexer: SPi Global Artist: SPi Global
Distributed to the book trade worldwide by Springer Science+Business Media New York, 233 Spring Street, 6th Floor, New York, NY 10013. Phone 1-800-SPRINGER, fax (201) 348-4505, email [email protected], or visit www.springeronline.com. Apress Media, LLC is a California LLC and the sole member (owner) is Springer Science + Business Media Finance Inc (SSBM Finance Inc). SSBM Finance Inc is a Delaware corporation.
For information on translations, please e-mail [email protected], or visit www.apress.com.
Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use. eBook versions and licenses are also available for most titles. For more information, reference our Special Bulk Sales–eBook Licensing web page at www.apress.com/bulk-sales.
Any source code or other supplementary material referenced by the author in this text is available to readers at www.apress.com/. For detailed information about how to locate your book’s source code, go to www.apress.com/source-code/.
To those in search of knowledge and better understanding, I dedicate this effort. Hopefully, as your skills grow,
you too will continue to share the wealth.
—Doug Gault
v
Contents at a Glance
About the Authors ���������������������������������������������������������������������������������������������������xix
About the Technical Reviewer ��������������������������������������������������������������������������������xxi
Acknowledgments ������������������������������������������������������������������������������������������������xxiii
■Chapter 1: An Introduction to APEX 5�0 ����������������������������������������������������������������� 1
■Chapter 2: A Developer’s Overview ����������������������������������������������������������������������� 7
■Chapter 3: Identifying the Problem and Designing the Solution �������������������������� 37
■Chapter 4: SQL Workshop ������������������������������������������������������������������������������������ 45
■Chapter 5: Applications and Navigation �������������������������������������������������������������� 67
■Chapter 6: Forms and Reports: The Basics ������������������������������������������������������� 107
■Chapter 7: Forms and Reports: Advanced ��������������������������������������������������������� 167
■Chapter 8: Programmatic Elements ������������������������������������������������������������������ 231
■Chapter 9: Security �������������������������������������������������������������������������������������������� 259
■Chapter 10: Application Bundling and Deployment ������������������������������������������� 287
■Chapter 11: Understanding Websheets ������������������������������������������������������������� 309
■Chapter 12: A Websheet Example ���������������������������������������������������������������������� 339
■Chapter 13: Extended Developer Tools �������������������������������������������������������������� 359
■Chapter 14: Managing Workspaces ������������������������������������������������������������������� 383
vi
â– Contents at a GlanCe
■Chapter 15: Team Development ������������������������������������������������������������������������� 401
■Chapter 16: Dynamic Actions ���������������������������������������������������������������������������� 431
■Appendix A: Page Designer Walkthrough and Reference ���������������������������������� 449
Index ��������������������������������������������������������������������������������������������������������������������� 469
vii
Contents
About the Author ����������������������������������������������������������������������������������������������������xix
About the Technical Reviewer ��������������������������������������������������������������������������������xxi
Acknowledgments ������������������������������������������������������������������������������������������������xxiii
■Chapter 1: An Introduction to APEX 5�0 ����������������������������������������������������������������� 1
What Is APEX? ������������������������������������������������������������������������������������������������������������������ 1
A Brief History of APEX ����������������������������������������������������������������������������������������������������� 2
Ancient History ��������������������������������������������������������������������������������������������������������������������������������������� 2
More Recent History ������������������������������������������������������������������������������������������������������������������������������� 2
APEX 5�0 and the Future ������������������������������������������������������������������������������������������������������������������������� 3
What You Need to Get Started ������������������������������������������������������������������������������������������ 4
Access to an APEX Instance ������������������������������������������������������������������������������������������������������������������� 5
Web Browser ������������������������������������������������������������������������������������������������������������������������������������������ 5
SQL Developer ���������������������������������������������������������������������������������������������������������������������������������������� 5
Summary �������������������������������������������������������������������������������������������������������������������������� 6
■Chapter 2: A Developer’s Overview ����������������������������������������������������������������������� 7
The Anatomy of a Workspace ������������������������������������������������������������������������������������������� 7
APEX Users ��������������������������������������������������������������������������������������������������������������������������������������������� 8
Applications, Pages, Regions, and Items ������������������������������������������������������������������������������������������������ 9
Workspaces, Applications, and Schemas ��������������������������������������������������������������������������������������������� 10
A Final Word on Workspaces ���������������������������������������������������������������������������������������������������������������� 12
A Tour of the APEX Modules ������������������������������������������������������������������������������������������� 12
The Home Page ������������������������������������������������������������������������������������������������������������������������������������ 13
Application Builder ������������������������������������������������������������������������������������������������������������������������������� 16
viii
â– Contents
SQL Workshop �������������������������������������������������������������������������������������������������������������������������������������� 19
Packaged Apps ������������������������������������������������������������������������������������������������������������������������������������� 32
Administration and Team Development ������������������������������������������������������������������������������������������������ 35
Summary ������������������������������������������������������������������������������������������������������������������������ 36
■Chapter 3: Identifying the Problem and Designing the Solution �������������������������� 37
Identifying System Requirements ���������������������������������������������������������������������������������� 37
Never a Clean Slate ������������������������������������������������������������������������������������������������������������������������������ 37
A Broken System ���������������������������������������������������������������������������������������������������������������������������������� 38
How Do You Fix Things? ������������������������������������������������������������������������������������������������������������������������ 38
System Design with APEX in Mind ��������������������������������������������������������������������������������� 40
Table Definition and User-Interface Defaults ���������������������������������������������������������������������������������������� 40
APEX and Primary Keys ������������������������������������������������������������������������������������������������������������������������ 41
Business Logic vs� User-Interface Logic ����������������������������������������������������������������������������������������������� 41
Placement of Database Objects ������������������������������������������������������������������������������������������������������������ 42
Translating Theory to Practice ���������������������������������������������������������������������������������������� 42
Summary ������������������������������������������������������������������������������������������������������������������������ 43
■Chapter 4: SQL Workshop ������������������������������������������������������������������������������������ 45
Creating Objects with the Object Browser ��������������������������������������������������������������������� 45
Loading Data with the Data Workshop Utility ����������������������������������������������������������������� 52
Creating a Lookup Table ������������������������������������������������������������������������������������������������� 57
Loading and Running SQL Scripts ���������������������������������������������������������������������������������� 60
User Interface Defaults ��������������������������������������������������������������������������������������������������� 64
Understanding User Interface Defaults ������������������������������������������������������������������������������������������������� 64
Defining UI Defaults for Tables ������������������������������������������������������������������������������������������������������������� 64
Summary ������������������������������������������������������������������������������������������������������������������������ 66
■Chapter 5: Applications and Navigation �������������������������������������������������������������� 67
The Create Application Wizard ���������������������������������������������������������������������������������������� 67
Sample and Packaged Applications ����������������������������������������������������������������������������������������������������� 68
Websheet Applications ������������������������������������������������������������������������������������������������������������������������� 72
ix
â– Contents
Database Applications from Spreadsheets ������������������������������������������������������������������������������������������� 72
Applications from Scratch �������������������������������������������������������������������������������������������������������������������� 73
Static Content Regions ��������������������������������������������������������������������������������������������������� 82
Public Pages ������������������������������������������������������������������������������������������������������������������� 87
Navigation Bar Entries ���������������������������������������������������������������������������������������������������� 88
Global Pages ������������������������������������������������������������������������������������������������������������������� 91
Breadcrumb Regions ������������������������������������������������������������������������������������������������������ 93
Breadcrumb Entries ������������������������������������������������������������������������������������������������������� 98
Lists �������������������������������������������������������������������������������������������������������������������������������� 99
Lists of Values ������������������������������������������������������������������������������������������������������������� 102
Static List of Values ���������������������������������������������������������������������������������������������������������������������������� 103
Dynamic List of Values������������������������������������������������������������������������������������������������������������������������ 104
Summary ���������������������������������������������������������������������������������������������������������������������� 106
■Chapter 6: Forms and Reports: The Basics ������������������������������������������������������� 107
APEX Forms ������������������������������������������������������������������������������������������������������������������ 107
Form on a Table ������������������������������������������������������������������������������������������������������������ 109
Creating a Form on a Table ����������������������������������������������������������������������������������������������������������������� 109
Modifying a Form on a Table �������������������������������������������������������������������������������������������������������������� 115
Looking Behind the Scenes ���������������������������������������������������������������������������������������������������������������� 120
Form on a Procedure ���������������������������������������������������������������������������������������������������� 122
Creating a Form on a Procedure ��������������������������������������������������������������������������������������������������������� 122
Modifying a Form on a Procedure ������������������������������������������������������������������������������������������������������ 125
Looking Behind the Scenes ���������������������������������������������������������������������������������������������������������������� 126
Master–Detail Report and Form ����������������������������������������������������������������������������������� 127
Creating a Master–Detail Report and Form ���������������������������������������������������������������������������������������� 127
Modifying a Master-Detail Report ������������������������������������������������������������������������������������������������������� 132
Session State ��������������������������������������������������������������������������������������������������������������� 137
Understanding Session State ������������������������������������������������������������������������������������������������������������� 137
Sharing Database Connections ����������������������������������������������������������������������������������������������������������� 138
x
â– Contents
Setting and Retrieving Session State ������������������������������������������������������������������������������������������������� 139
Viewing Session State ������������������������������������������������������������������������������������������������������������������������ 140
APEX Items ������������������������������������������������������������������������������������������������������������������� 141
Page vs� Application Items������������������������������������������������������������������������������������������������������������������ 142
The Importance of Bind Variables ������������������������������������������������������������������������������������������������������� 142
Built-In Items �������������������������������������������������������������������������������������������������������������������������������������� 143
APEX URL Syntax ���������������������������������������������������������������������������������������������������������� 143
Searchable APEX Reports ��������������������������������������������������������������������������������������������� 145
Creating a Searchable APEX Report���������������������������������������������������������������������������������������������������� 145
Adding Reset Pagination��������������������������������������������������������������������������������������������������������������������� 147
Looking Behind the Scenes—APEX Report ���������������������������������������������������������������������������������������� 148
Looking Behind the Scenes—APEX Master–Detail Forms ����������������������������������������������������������������� 150
More on APEX Forms ���������������������������������������������������������������������������������������������������� 152
Item Layout ����������������������������������������������������������������������������������������������������������������������������������������� 152
Placing Multiple Items in the Same Row �������������������������������������������������������������������������������������������� 154
Implementing LOVs ����������������������������������������������������������������������������������������������������������������������������� 156
Master–Detail Cleanup ����������������������������������������������������������������������������������������������������������������������� 159
APEX Help ��������������������������������������������������������������������������������������������������������������������� 160
Adding a Help Text Region ������������������������������������������������������������������������������������������������������������������ 161
Seeding Help Text ������������������������������������������������������������������������������������������������������������������������������� 162
Declarative BLOBs �������������������������������������������������������������������������������������������������������� 163
Summary ���������������������������������������������������������������������������������������������������������������������� 166
■Chapter 7: Forms and Reports: Advanced ��������������������������������������������������������� 167
Tabular Forms �������������������������������������������������������������������������������������������������������������� 167
Creating a Tabular Form ��������������������������������������������������������������������������������������������������������������������� 167
Modifying a Tabular Form ������������������������������������������������������������������������������������������������������������������� 172
Looking Behind the Scenes ���������������������������������������������������������������������������������������������������������������� 176
Interactive Reports ������������������������������������������������������������������������������������������������������� 177
Creating an Interactive Report ������������������������������������������������������������������������������������������������������������ 177
Running an Interactive Report ������������������������������������������������������������������������������������������������������������ 181
xi
â– Contents
Restricting Functionality by Report ���������������������������������������������������������������������������������������������������� 182
Restricting Functionality by Column ��������������������������������������������������������������������������������������������������� 184
Using the Column Heading Menu ������������������������������������������������������������������������������������������������������� 184
Searching by Column �������������������������������������������������������������������������������������������������������������������������� 185
Selecting Columns ������������������������������������������������������������������������������������������������������������������������������ 188
Filtering ���������������������������������������������������������������������������������������������������������������������������������������������� 188
Sorting ������������������������������������������������������������������������������������������������������������������������������������������������ 191
Adding Breaks ������������������������������������������������������������������������������������������������������������������������������������ 191
Highlighting ���������������������������������������������������������������������������������������������������������������������������������������� 192
Computing Columns ��������������������������������������������������������������������������������������������������������������������������� 193
Adding Aggregates ����������������������������������������������������������������������������������������������������������������������������� 194
Adding Charts to Interactive Reports �������������������������������������������������������������������������������������������������� 194
Grouping ��������������������������������������������������������������������������������������������������������������������������������������������� 196
Pivot ���������������������������������������������������������������������������������������������������������������������������������������������������� 197
Using Flashback ��������������������������������������������������������������������������������������������������������������������������������� 198
Saving an Interactive Report �������������������������������������������������������������������������������������������������������������� 198
Resetting an Interactive Report ���������������������������������������������������������������������������������������������������������� 200
Getting Help ���������������������������������������������������������������������������������������������������������������������������������������� 200
Adding a Subscription ������������������������������������������������������������������������������������������������������������������������ 201
Downloading ��������������������������������������������������������������������������������������������������������������������������������������� 202
Modifying an Interactive Report ��������������������������������������������������������������������������������������������������������� 204
Looking Behind the Scenes ���������������������������������������������������������������������������������������������������������������� 212
Calendars ��������������������������������������������������������������������������������������������������������������������� 213
Understanding Calendar Types ����������������������������������������������������������������������������������������������������������� 214
Creating a Calendar ���������������������������������������������������������������������������������������������������������������������������� 214
Looking Behind the Scenes ���������������������������������������������������������������������������������������������������������������� 222
Charts ��������������������������������������������������������������������������������������������������������������������������� 222
Writing Queries for Charts ������������������������������������������������������������������������������������������������������������������ 223
Creating a Chart ���������������������������������������������������������������������������������������������������������������������������������� 224
xii
â– Contents
Filtering Data for a Chart �������������������������������������������������������������������������������������������������������������������� 226
Looking Behind the Scenes ���������������������������������������������������������������������������������������������������������������� 229
Summary ���������������������������������������������������������������������������������������������������������������������� 229
■Chapter 8: Programmatic Elements ������������������������������������������������������������������ 231
Conditions �������������������������������������������������������������������������������������������������������������������� 231
Required Values ������������������������������������������������������������������������������������������������������������ 231
Validations �������������������������������������������������������������������������������������������������������������������� 234
Item-Level Validation �������������������������������������������������������������������������������������������������������������������������� 234
Page-Level Validation ������������������������������������������������������������������������������������������������������������������������� 238
Tabular Form Validation ���������������������������������������������������������������������������������������������������������������������� 240
Computations ��������������������������������������������������������������������������������������������������������������� 242
Execution �������������������������������������������������������������������������������������������������������������������������������������������� 242
Types �������������������������������������������������������������������������������������������������������������������������������������������������� 243
Creating a Computation ���������������������������������������������������������������������������������������������������������������������� 243
Processes ��������������������������������������������������������������������������������������������������������������������� 246
Execution Points ��������������������������������������������������������������������������������������������������������������������������������� 247
Process Types ������������������������������������������������������������������������������������������������������������������������������������� 247
Processes in the Help Desk Application ��������������������������������������������������������������������������������������������� 248
PL/SQL Regions ������������������������������������������������������������������������������������������������������������ 251
Dynamic SQL ���������������������������������������������������������������������������������������������������������������� 253
Summary ���������������������������������������������������������������������������������������������������������������������� 258
■Chapter 9: Security �������������������������������������������������������������������������������������������� 259
User-Maintenance Navigation ������������������������������������������������������������������������������������� 259
User-Maintenance Data Entry �������������������������������������������������������������������������������������� 263
Authentication �������������������������������������������������������������������������������������������������������������� 269
Custom Authentication Schemes ��������������������������������������������������������������������������������� 270
Conditional Security ����������������������������������������������������������������������������������������������������� 272
Access Control ������������������������������������������������������������������������������������������������������������� 273
Authorization ���������������������������������������������������������������������������������������������������������������� 276
xiii
â– Contents
Read-Only Items ����������������������������������������������������������������������������������������������������������� 279
Data Security ���������������������������������������������������������������������������������������������������������������� 281
Session-State Protection ���������������������������������������������������������������������������������������������� 284
Summary ���������������������������������������������������������������������������������������������������������������������� 285
■Chapter 10: Application Bundling and Deployment ������������������������������������������� 287
Identifying Application Components ����������������������������������������������������������������������������� 287
External Files �������������������������������������������������������������������������������������������������������������������������������������� 288
Database Objects �������������������������������������������������������������������������������������������������������������������������������� 288
APEX-Based Files ������������������������������������������������������������������������������������������������������������������������������� 294
APEX Application Exports �������������������������������������������������������������������������������������������������������������������� 296
Supporting Objects ������������������������������������������������������������������������������������������������������� 299
Prerequisites��������������������������������������������������������������������������������������������������������������������������������������� 300
Substitutions ��������������������������������������������������������������������������������������������������������������������������������������� 301
Build Options �������������������������������������������������������������������������������������������������������������������������������������� 301
Validations ������������������������������������������������������������������������������������������������������������������������������������������ 301
Install �������������������������������������������������������������������������������������������������������������������������������������������������� 301
Upgrade ���������������������������������������������������������������������������������������������������������������������������������������������� 303
Deinstall ���������������������������������������������������������������������������������������������������������������������������������������������� 303
Export ������������������������������������������������������������������������������������������������������������������������������������������������� 303
Messages ������������������������������������������������������������������������������������������������������������������������������������������� 303
Importing ���������������������������������������������������������������������������������������������������������������������� 304
Summary ���������������������������������������������������������������������������������������������������������������������� 308
■Chapter 11: Understanding Websheets ������������������������������������������������������������� 309
Websheet Structure ������������������������������������������������������������������������������������������������������ 309
Navigation �������������������������������������������������������������������������������������������������������������������� 311
Content Navigation ����������������������������������������������������������������������������������������������������������������������������� 311
Structural Navigation �������������������������������������������������������������������������������������������������������������������������� 313
Help ������������������������������������������������������������������������������������������������������������������������������ 313
Markup Syntax ������������������������������������������������������������������������������������������������������������� 315
xiv
â– Contents
User Authentication ������������������������������������������������������������������������������������������������������ 316
User Authorization �������������������������������������������������������������������������������������������������������� 318
Sections������������������������������������������������������������������������������������������������������������������������ 323
Text Sections �������������������������������������������������������������������������������������������������������������������������������������� 323
Navigation Sections ���������������������������������������������������������������������������������������������������������������������������� 326
Data Sections ������������������������������������������������������������������������������������������������������������������������������������� 327
Chart Sections ������������������������������������������������������������������������������������������������������������������������������������ 337
Annotations ������������������������������������������������������������������������������������������������������������������ 337
Administration �������������������������������������������������������������������������������������������������������������� 338
Summary ���������������������������������������������������������������������������������������������������������������������� 338
■Chapter 12: A Websheet Example ���������������������������������������������������������������������� 339
Setup ���������������������������������������������������������������������������������������������������������������������������� 339
Creating and Configuring a Websheet Application ������������������������������������������������������� 340
Adding Content to a Websheet ������������������������������������������������������������������������������������� 345
Creating Data Grids ����������������������������������������������������������������������������������������������������������������������������� 345
Applying Constraints ��������������������������������������������������������������������������������������������������������������������������� 347
Adding Players ������������������������������������������������������������������������������������������������������������������������������������ 348
Creating Alternate Default Reports ����������������������������������������������������������������������������������������������������� 349
Creating Page Sections ���������������������������������������������������������������������������������������������������������������������� 350
SQL Tags ��������������������������������������������������������������������������������������������������������������������������������������������� 357
Access Controls ������������������������������������������������������������������������������������������������������������ 358
Summary ���������������������������������������������������������������������������������������������������������������������� 358
■Chapter 13: Extended Developer Tools �������������������������������������������������������������� 359
Page Locks ������������������������������������������������������������������������������������������������������������������� 359
APEX Conflicts ������������������������������������������������������������������������������������������������������������������������������������ 360
Locking an APEX Page ������������������������������������������������������������������������������������������������������������������������ 360
Unlocking a Page �������������������������������������������������������������������������������������������������������������������������������� 361
Administering Page Locks ������������������������������������������������������������������������������������������������������������������ 361
xv
â– Contents
Application and Page Groups ��������������������������������������������������������������������������������������� 362
Application Groups ����������������������������������������������������������������������������������������������������������������������������� 362
Page Groups ��������������������������������������������������������������������������������������������������������������������������������������� 364
APEX Views and the APEX Dictionary ��������������������������������������������������������������������������� 364
The APEX Schema ������������������������������������������������������������������������������������������������������������������������������� 365
APEX Views ����������������������������������������������������������������������������������������������������������������������������������������� 365
APEX Dictionary ���������������������������������������������������������������������������������������������������������������������������������� 368
Searching in APEX �������������������������������������������������������������������������������������������������������� 368
APEX Finder ���������������������������������������������������������������������������������������������������������������������������������������� 368
Search Application ������������������������������������������������������������������������������������������������������������������������������ 369
Monitoring Your APEX Application �������������������������������������������������������������������������������� 371
Enabling Logging �������������������������������������������������������������������������������������������������������������������������������� 371
Using the Activity Logs ����������������������������������������������������������������������������������������������������������������������� 372
Login Attempts ������������������������������������������������������������������������������������������������������������������������������������ 373
APEX Advisor ���������������������������������������������������������������������������������������������������������������� 373
Build Options ���������������������������������������������������������������������������������������������������������������� 375
Understanding the Need ��������������������������������������������������������������������������������������������������������������������� 375
Creating a Build Option ����������������������������������������������������������������������������������������������������������������������� 376
Configuring Build Options ������������������������������������������������������������������������������������������������������������������� 377
Prompting for Build Option Status ������������������������������������������������������������������������������������������������������ 377
Applying Build Options������������������������������������������������������������������������������������������������������������������������ 378
Reporting on Build Option Utilization �������������������������������������������������������������������������������������������������� 379
Page-Specific Utilities �������������������������������������������������������������������������������������������������� 379
APEX and Oracle SQL Developer ���������������������������������������������������������������������������������� 380
Integration ������������������������������������������������������������������������������������������������������������������������������������������ 380
Refactoring Support���������������������������������������������������������������������������������������������������������������������������� 381
Summary ���������������������������������������������������������������������������������������������������������������������� 382
xvi
â– Contents
■Chapter 14: Managing Workspaces ������������������������������������������������������������������� 383
Learning About Your Environment �������������������������������������������������������������������������������� 383
Viewing Instance Information ������������������������������������������������������������������������������������������������������������� 384
Checking the APEX Version ����������������������������������������������������������������������������������������������������������������� 385
Managing the Service �������������������������������������������������������������������������������������������������� 385
Workspace Preferences ���������������������������������������������������������������������������������������������������������������������� 386
Messages ������������������������������������������������������������������������������������������������������������������������������������������� 387
Managing Meta Data ���������������������������������������������������������������������������������������������������� 388
Developer Activity and Click Count Logs �������������������������������������������������������������������������������������������� 388
Session State �������������������������������������������������������������������������������������������������������������������������������������� 389
Application Cache ������������������������������������������������������������������������������������������������������������������������������� 390
Websheet Database Objects ��������������������������������������������������������������������������������������������������������������� 390
Application Build Status ��������������������������������������������������������������������������������������������������������������������� 391
File Utilization ������������������������������������������������������������������������������������������������������������������������������������� 391
Interactive Report Settings ����������������������������������������������������������������������������������������������������������������� 392
Managing Users and Groups ���������������������������������������������������������������������������������������� 393
Creating One User ������������������������������������������������������������������������������������������������������������������������������� 393
Creating Multiple Users ���������������������������������������������������������������������������������������������������������������������� 394
Organizing Users into Groups ������������������������������������������������������������������������������������������������������������� 396
Viewing Usage Reports and Dashboards ��������������������������������������������������������������������� 399
Summary ���������������������������������������������������������������������������������������������������������������������� 399
■Chapter 15: Team Development ������������������������������������������������������������������������� 401
Team Development Overview ��������������������������������������������������������������������������������������� 401
Team Development Interface ��������������������������������������������������������������������������������������� 403
APEX Home Page �������������������������������������������������������������������������������������������������������������������������������� 403
Team Development Home Page ���������������������������������������������������������������������������������������������������������� 404
Common Design Elements ������������������������������������������������������������������������������������������������������������������ 405
Drilldown Functionality ����������������������������������������������������������������������������������������������������������������������� 406
Tagging ����������������������������������������������������������������������������������������������������������������������������������������������� 408
xvii
â– Contents
Milestones �������������������������������������������������������������������������������������������������������������������� 409
Milestones Report Tab ������������������������������������������������������������������������������������������������������������������������ 409
By Owner Tab �������������������������������������������������������������������������������������������������������������������������������������� 410
Features by Milestone Tab ������������������������������������������������������������������������������������������������������������������ 410
Features ����������������������������������������������������������������������������������������������������������������������� 411
Features Report Tab ���������������������������������������������������������������������������������������������������������������������������� 411
History Tab ������������������������������������������������������������������������������������������������������������������������������������������ 413
Progress Log Tab �������������������������������������������������������������������������������������������������������������������������������� 413
To-Do Items ������������������������������������������������������������������������������������������������������������������ 414
Bugs ����������������������������������������������������������������������������������������������������������������������������� 415
Feedback ���������������������������������������������������������������������������������������������������������������������� 416
Configuring Feedback ������������������������������������������������������������������������������������������������������������������������� 416
Polishing the Feedback Page ������������������������������������������������������������������������������������������������������������� 419
Viewing Feedback ������������������������������������������������������������������������������������������������������������������������������ 423
Responses to Feedback ���������������������������������������������������������������������������������������������������������������������� 423
Communication Between Workspaces ����������������������������������������������������������������������������������������������� 423
Team Development Utilities ������������������������������������������������������������������������������������������ 424
Team Development Settings ��������������������������������������������������������������������������������������������������������������� 424
Release Summary ������������������������������������������������������������������������������������������������������������������������������ 425
Enable Files ���������������������������������������������������������������������������������������������������������������������������������������� 426
Feature Utilities ���������������������������������������������������������������������������������������������������������������������������������� 426
Manage Focus Areas �������������������������������������������������������������������������������������������������������������������������� 427
Update Assignees ������������������������������������������������������������������������������������������������������������������������������� 427
View Files ������������������������������������������������������������������������������������������������������������������������������������������� 427
Purge Data ������������������������������������������������������������������������������������������������������������������������������������������ 427
Manage News ������������������������������������������������������������������������������������������������������������������������������������� 428
Manage Links ������������������������������������������������������������������������������������������������������������������������������������� 428
User Roles for Team Development ������������������������������������������������������������������������������� 429
Summary ���������������������������������������������������������������������������������������������������������������������� 429
xviii
â– Contents
■Chapter 16: Dynamic Actions ���������������������������������������������������������������������������� 431
Dynamic Action Benefits ���������������������������������������������������������������������������������������������� 431
Breaking Down Dynamic Actions ��������������������������������������������������������������������������������� 431
Dynamic Actions in the Help Desk Application ������������������������������������������������������������� 432
Starting Simple ����������������������������������������������������������������������������������������������������������������������������������� 432
Using Page-Level Events �������������������������������������������������������������������������������������������������������������������� 439
Dynamic Actions with Multiple Triggering Elements �������������������������������������������������������������������������� 441
Dynamic Actions Using PL/SQL ����������������������������������������������������������������������������������������������������������� 443
Dynamic Actions Using JavaScript ����������������������������������������������������������������������������������������������������� 445
Summary ���������������������������������������������������������������������������������������������������������������������� 447
■Appendix A: Page Designer Walkthrough and Reference ���������������������������������� 449
Page Designer Overview ���������������������������������������������������������������������������������������������� 449
Page Designer Toolbar �������������������������������������������������������������������������������������������������� 451
Tree Pane���������������������������������������������������������������������������������������������������������������������� 453
Central Pane ����������������������������������������������������������������������������������������������������������������� 454
Grid Layout ����������������������������������������������������������������������������������������������������������������������������������������� 455
Messages ������������������������������������������������������������������������������������������������������������������������������������������� 457
Page Search ��������������������������������������������������������������������������������������������������������������������������������������� 458
Help ���������������������������������������������������������������������������������������������������������������������������������������������������� 459
Property Editor ������������������������������������������������������������������������������������������������������������� 460
Gallery �������������������������������������������������������������������������������������������������������������������������� 467
Keyboard Shortcuts ������������������������������������������������������������������������������������������������������ 467
Summary ���������������������������������������������������������������������������������������������������������������������� 468
Index ��������������������������������������������������������������������������������������������������������������������� 469
xix
About the Author
Doug Gault is a Consulting Member of Technical Staff at Oracle Corporation and has been working with Oracle since 1988, starting with version 5.1B, SQL*Forms 2.0, and RPT/RPF. He has focused his career on Oracle’s development technologies, spending the majority of that time dedicated to web-based technologies, including the OWA Web Toolkit, PL/SQL Server Pages, WebDB, Oracle Portal, and more recently HTML-DB and APEX.
His many years of Oracle experience have taken him all over the world to participate in some truly groundbreaking projects. Doug has presented and participated in roundtable discussions at a number of conferences, including Oracle OpenWorld, UKOUG, and ODTUG’s APEXposed & Kaleidoscope conferences. He holds an Associate’s Degree in Computer Science and an honorary Master’s Degree from The School of Hard Knocks, believing there is no replacement for hard-earned experience.
Doug can be found on Twitter as @dgault_apex and on his blog at douggault.blogspot.com.
xxi
About the Technical Reviewer
Warren Capps, president of Illuminations Inc, has worked with Oracle since 1987 when he worked on version 5.1a. Since 1991, his principal efforts have been spent in training clients in the use of Oracle products, concentrating on database server technologies. He is a well-known presenter at user-group conferences and has written numerous articles and book reviews for a variety of publications. He also ran an Oracle bookstore for ten years and is a retired Navy Commander.
When not teaching, Warren has myriad activities to keep him busy. He is an avid photographer and has run photography workshops in southern New Mexico. His photography has led him to visit over 25 countries. Additionally, he plays classical guitar, collects coins, and loves to travel the country with his wife and cat. He is currently a resident of Austin, Texas.
xxiii
Acknowledgments
First, my heart-felt thanks to all the co-authors of the original version of this book: Karen Cannell, Patrick Cimolini, Martin D’Souza, and Tim St. Hilaire. Warren Capps also needs to be thanked for his technical review efforts and his input on content and form. If not for these wonderful people, this book may never have come to be. The opportunity to work with such a talented and distinguished group of individuals has been a pleasure.
I’d also like to thank a few people who have been driving forces in my life: Kerry Osborne for providing me with an immense amount of mentorship and encouragement over the years, even after having left his employ; Cary Millsap for his friendship and helping to solidify in my mind how to think objectively about technology and to use proof to find the truth; and last but not least, Scott Spendolini for his all-around support before, during, and after the book. Without these people, I wouldn’t be where I am today.
—Doug Gault