Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
63 views

BC 414 - Programming Database Changes

This document discusses database updates in SAP systems. It covers topics like using OPENSQL to perform database operations, logical units of work (LUWs), client/server architecture, locking concepts, organizing database updates using log tables, complex LUW processing, and change documents. The document is divided into six units and provides notes on concepts like buffer types, cluster tables, transparent tables, and BAPIs.

Uploaded by

yasra shakil
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
63 views

BC 414 - Programming Database Changes

This document discusses database updates in SAP systems. It covers topics like using OPENSQL to perform database operations, logical units of work (LUWs), client/server architecture, locking concepts, organizing database updates using log tables, complex LUW processing, and change documents. The document is divided into six units and provides notes on concepts like buffer types, cluster tables, transparent tables, and BAPIs.

Uploaded by

yasra shakil
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

BC414

Thursday, May 28, 2015 4:51 PM

BC414
Programming Database Updates
SAP NetWeaver
-- Zhang Ning

Unit 1: Database Updates with Open SQL

OPENDSQL通过应用层数据库接口实现对数据库层数据的数据库无关性操作

OPENSQL命令提供一个返回值sy-subrc
0代表成功其他的代表失败

sy-dbcnt显示了数据库操作实际操作了多少行

MANDT字段代表该数据库表示client-specific的

删除数据库所有行
DELETE FROM <dbtab> WHERE <field> LIKE "%"

Unit 2: LUWs and Client/Server Architecture


Unit 3: SAP Locking Concept

Quick Notes Page 1


LUW: Logic Unit of Work

The SAP-LUW must be processed within a DB-LUW.

加锁是为了避免并发访问异常

E Write lock
S Read lock
X Extended write lock

Use and Effect of the Lock Modes

Unit 4: Organizing Database Updates

Step 1: The dialog program receives the data updated by the user and writes it to a
special log table.
Step 2: The dialog program closes the logical data packet (LUW) that was written
to the log table,
Step 3: A basis program reads the data associated with the LUW from the log
table and supplies it to the update program.
Step 4: The update program accepts the data transferred to it and updates the

Quick Notes Page 2


Step 4: The update program accepts the data transferred to it and updates the
database entries.
Step 5: If the update program runs successfully, a Basis program deletes all entries
for the LUW from the log table.

Unit 5: Complex LUW Processing

程序间的数据传递

Unit 6: Appendix
Principle of Creating Change Documents

Quick Notes Page 3


The general document data includes:
• Object Class: Name of the change document object used
• User ID: At document creation, you can decide the name of the document
(for later document search, generally tontains the key of the changed records)
• Change Number The number automatically assigned to the document

Tools → ABAP Workbench → Development → Other Tools → Authorization


Objects.

执行授权检查:

Quick Notes Page 4


执行授权检查:

Buffer Types:

Cluster Tables and Transparent Tables

Quick Notes Page 5


BAPI:
Business Application Programming Interface

Quick Notes Page 6

You might also like