---
title: "ABAP里面的Sleep函数"
author: "JavaFans"
date: "2011-05-06T10:55:49Z"
tags: ["UP"]
categories: ["编程语言"]
slug: "abap-sleep"
draft: false
lastmod: "2011-05-06T10:55:49Z"
id: 1032820
url: "https://javafans.iteye.com/blog/1032820"
---

```
wait up to 42 seconds.
```

- Does a roll-out and releases the work process to the listener
- Does an implicit Database commit

Use when CPU processes are at a premium and when the implicit commit will not corrupt your data or cause a short dump because of an open database cursor.

```
    CALL FUNCTION 'ENQUE_SLEEP'
      EXPORTING
        seconds              = 42.
```

- Does not release the work process
- Does not cause an implicit Database commit

Use when you cannot afford an implicit commit, and the system can handle the work process(es) being tied up for the duration of the SLEEP command.