feat: add benchmark-programs — 58 telecom COBOL test programs
作为子目录纳入系统,与核心测试管道协同 Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
# 23-select-condition — SELECT Condition Simulation
|
||||
|
||||
## 电信业务场景
|
||||
|
||||
客户合同检索。使用索引文件模拟SELECT条件检索,通过START+READ NEXT实现条件匹配和范围查询。
|
||||
|
||||
## Purpose
|
||||
Simulates SQL SELECT with WHERE conditions using GnuCOBOL INDEXED files and START/READ NEXT operations.
|
||||
|
||||
## Test Coverage
|
||||
1. **Single record by key** — READ with KEY IS (exact match WHERE)
|
||||
2. **Range query** — START with NOT LESS THAN, loop with upper bound check
|
||||
3. **Zero results** — Key not found, INVALID KEY handling
|
||||
4. **Greater-than query** — START with GREATER THAN, read all following records
|
||||
|
||||
## Key Techniques
|
||||
- INDEXED file ORGANIZATION with DYNAMIC access
|
||||
- START for positioning (KEY IS GREATER THAN / NOT LESS THAN)
|
||||
- READ NEXT for sequential traversal
|
||||
- FILE STATUS checking
|
||||
- INVALID KEY / NOT INVALID KEY for conditional handling
|
||||
Reference in New Issue
Block a user