---
title: "DATE_ROUND"
description: "DATE_ROUND SQL\u95A2\u6570\u306F\u3001datetime\u306E\u4E38\u3081\u3089\u308C\u305F\u5024\u3092\u8FD4\u3057\u307E\u3059\u3002"
language: ja
source_language: en
translation_state: complete
canonical: https://documentation.invantive.eu/ja/docs/invantive-universalsql/grammar/sql-functions/date-round
original: https://documentation.invantive.eu/en/docs/invantive-universalsql/grammar/sql-functions/date-round
updated: 2026-12-04T13:32:49Z
license: https://documentation.invantive.eu/ja/
---

## 構文
```mermaid
%%{init: {
  'theme': 'base',
  'flowchart': { 'padding': '7', 'nodeSpacing': '20', 'rankSpacing': '20' },
  'themeVariables': {
    'fontSize': '11px',
    'fontFamily': 'Arial'
  }
}}%%
flowchart LR
    Start((START)) --> DATE_ROUND[DATE_ROUND]:::quoted
    DATE_ROUND --> End((END))
```

## 目的
`DATE_ROUND` SQL Function (*.fnc)は、`datetime`の丸められた値を返します。

[[DATE_CEIL]]、[[DATE_FLOOR]]、[[DATE_TRUNC]]もあわせて参照してください。

パラメータ:
- Precision (`varchar2`): one of `millenium`, `century`, `decade`, `year`, `quarter`, `month`, `week`, `day`, `hour`, `minute`, `second`, `milliseconds` and `microseconds`.
- 日付/時刻（`datetime`）：丸める日付/時刻。

戻り値：定義された精度で丸められた入力の日付/時刻を`datetime`として返します。 リストにない精度が指定された場合は、元の値が返されます。

## 例
次の例では、ミレニアム単位で丸められたシステム時刻の値を取得します：
```sql
select date_round('millenium', sysdateutc)

-------------------
01-01-2000 00:00:00
```
次の例では、10年単位で丸められたシステム時刻の値を取得します：
```sql
select date_round('decade', sysdateutc)

-------------------
01-01-2030 00:00:00
```

