Post-Query Samples
来源:互联网 发布:炒股软件开发 编辑:程序博客网 时间:2024/05/18 07:40
Perform an action after fetching a record, such as looking up values in other tables based on a value in the current record. Fires once for each record fetched into the block.
Description
When a query is open in the block, the Post-Query trigger fires each time Form Builder fetches a record into a block. The trigger fires once for each record placed on the block's list of records.
Definition Level form or block
Legal Commands
SELECT statements, unrestricted built-ins
Enter Query Mode no
Usage Notes
Use a Post-Query trigger to perform the following tasks:
*populate control items or items in other blocks
*calculate statistics about the records retrieved by a query
*calculate a running total
*When you use a Post-Query trigger to SELECT non-base table values into control items, Form Builder marks each record as CHANGED, and so fires the When-Validate-Item trigger by default. You can avoid the execution of the When-Validate-Item trigger by explicitly setting the Status property of each record to QUERY in the Post-Query trigger. To set record status programmatically, use SET_RECORD_PROPERTY .
On Failure
Form Builder flushes the record from the block and attempts to fetch the next record from the database. If there are no other records in the database, Form Builder closes the query and waits for the next operator action.
Sample 1
This example retrieves descriptions for code fields, for display in non-database items in the current block.
DECLARE CURSOR lookup_payplan IS SELECT Payplan_Desc FROM Payplan WHERE Payplan_Id = :Employee.Payplan_Id; CURSOR lookup_area IS SELECT Area_Name FROM Zip_Code WHERE Zip = :Employee.Zip; BEGIN /* ** Lookup the Payment Plan Description given the ** Payplan_Id in the Employee Record just fetched. ** Use Explicit Cursor for highest efficiency. */ OPEN lookup_payplan; FETCH lookup_payplan INTO :Employee.Payplan_Desc_Nondb; CLOSE lookup_payplan; /* ** Lookup Area Descript given the Zipcode in ** the Employee Record just fetched. Use Explicit ** Cursor for highest efficiency. */ OPEN lookup_area; FETCH lookup_area INTO :Employee.Area_Desc_Nondb; CLOSE lookup_area; END;
- Post-Query Samples
- Pre-Query Samples
- Samples
- Query Ajax 实例 ($.ajax、$.post、$.get)
- Query Ajax 实例 ($.ajax、$.post、$.get)
- Retrofit get post query filed FiledMap
- Query中$.get(),$.post(),$.ajax(),$.getJSON()的区别及用法
- AutoComplete Samples
- lhgdialog - samples
- Ajaxcontroltoolkit/Samples
- CUDA Samples
- Opencv samples
- ios samples
- IME samples
- iostat samples
- vmstat samples
- netstat samples
- DirectShow Samples
- 计算机网络----传输层
- 在ubuntu10.10, 打印机MFC-7340安装
- 根据二叉树的先序、中序遍历结果重建二叉树
- 用GDB调试Segmentation Fault错误
- 对九个超级程序员的采访
- Post-Query Samples
- 第五章 表达式
- 链表相邻元素翻转
- JSTL标签 参考手册
- 井号在宏定义中的特殊用法
- 矩形的并和交
- 我和你(3)
- Android 应用开发笔记 - 列表(ListView)& SimpleAdapter
- 秋雨寄相思