zoukankan      html  css  js  c++  java
  • SAP ABAP 性能优化技巧 — 使用 “for all entries”

    在select语句后面的where附加项中可以使用左关联,这会极大的提高程序速度,但同时也有一些局限,如下:

    1. 重复项会被从结果数据集中自动删除,因此要注意在select语句中需要给出详细的唯一关键字组合。
    2. 如果 For All Entries IN 字段修饰的内表是空表的话,源表的所有行都会被选入目标表中。因此在使用前一定要首先检查第一个表是否为空,这一点很重要,否则会有performance问题。
    3. 如果 For All Entries IN 字段修饰的内表很大的话,程序速度反而会减慢,而不是加快。因此应该尽量使该表的数据量控制在一个适当的大小。

    不推荐使用:

    Loop at int_cntry.

    Select single * from zfligh into int_fligh

    where cntry = int_cntry-cntry.

    Append int_fligh.

    Endloop.

    推荐使用:

    IF NOT int_cntry[] IS INITIAL.

      Select * from zfligh appending table int_fligh

    For all entries in int_cntry

    Where cntry = int_cntry-cntry.

    ENDIF.

  • 相关阅读:
    IIS WebDAV安全配置
    sql注入notebook
    sqlilabs less18-22 HTTP头的注入
    sqlilab less15-17
    sqlilab11-14
    sqlliab7-8
    sqli lab less-5-6
    sqli lab 1-4
    sql注入 pikachu
    [wp]xctf newscenter
  • 原文地址:https://www.cnblogs.com/levin/p/1537858.html
Copyright © 2011-2022 走看看