当前位置:网站首页>Usage of SAP ABAP for all entries
Usage of SAP ABAP for all entries
2022-04-22 18:00:00 【Jerry Wang】
FOR ALL ENTRIES Clause is ABAP OPEN SQL Functions commonly used in statements . with FOR ALL ENTRIES Clause OPEN SQL Statement represents a method that contains both database tables and ABAP Inner surface OPEN SQL Statement type . In the past we could use JOIN Transform to perform this SQL sentence . With fast data access (Fast Data Access, abbreviation FDA), You can use one FOR ALL ENTRIES Clause execution SQL New method of statement .
This article will explain SAP ABAP Data access in the kernel (FDA) How fast you work , And why with FOR ALL ENTRIES Clause OPEN SQL SELECT sentence ,FDA Than JOIN Conversion is more appropriate .
By default , Apply to Linux、UNIX and Windows Of IBM Db2 Shared database (DBSL) Use... For these statements FDA—— The premise is that Unicode The system has SAP kernel 7.49 Or later and database version 10.5 FP7 Or later .
ABAP For All entries Usage of
with FOR ALL ENTRIES Clause OPEN SQL Statement represents a method that contains both database tables and ABAP Internal table OPEN SQL Statement type .
The basic form of these statements is as follows :
SELECT <column list>
FROM < database tables>
FOR ALL ENTRIES IN @itab
WHERE < clause containing database table columns and itab columns>
Basically , This statement type implements database tables and ABAP Internal table itab Between JOIN. Only different rows in the result set are returned to ABAP Program . because ABAP The internal table is located at SAP On the application server , Therefore, you need to transfer the reference column values from the table to the database server .
A concrete example :
DATA: db6 LIKE standard table of t100.
DATA: db6out LIKE standard table of t100.
DATA: start_time TYPE i,
end_time TYPE i,
run_time TYPE float.
SELECT * FROM t100 UP TO 100000 ROWS INTO TABLE db6 .
GET RUN TIME FIELD start_time.
SELECT * INTO TABLE db6out FROM t100
BYPASSING BUFFER
FOR ALL ENTRIES IN db6
WHERE sprsl = db6-sprsl
AND arbgb = db6-arbgb
AND msgnr = db6-msgnr.
GET RUN TIME FIELD end_time.
run_time = end_time – start_time .
WRITE : / run_time .
Test program from database table T100 Choose from 100,000 Go to a named db6 In the internal table of . thereafter , Program usage FOR ALL ENTRIES Statement to the database table T100 And internal table db6 Connect . Because the connection uses a table T100 The primary key column of , therefore FOR ALL ENTRIES Statement will return 100,000 That's ok . The program shows FOR ALL ENTRIES Elapsed time of statement use .
版权声明
本文为[Jerry Wang]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204221753487059.html
边栏推荐
猜你喜欢
随机推荐
L1-025 positive integer a + B (15 points)
Dpdk captures traffic from a given port / queue
Common error reporting records
即使 Outlook Deleted Items 文件夹清空之后,仍然可以恢复被删除的邮件
dpdk从环形队列ring获取解析数据包,并使用hashtable统计
Must brush the simulated question bank and answers of the latest eight members of Jiangxi in 2022
Examples of comprehensive application of DOM -- click plus one and minus one
[Lane] ultra fast lane detection (1) custom dataset training
软考高项笔记 | 信息系统安全
DOM的综合应用的例子--点击加一和减一
Get the actual name of the parameter of the method through reflection
Why has Sony always dominated the smartphone sensor market
An understanding process and its communication method
秒云助力中电科32所发布“基于拟态应用集成框架的SaaS云管理平台解决方案”
Multithreading notes | compare thread and runnable
Spacy tutorial learning
Soft test high item notes | basis of project evaluation
PiKachu-File Inclusion(文件包含漏洞)
Go operation MySQL
Secyun assisted the "SaaS cloud management platform solution based on pseudo application integration framework" released by CETC 32





