---
title: "LOG"
description: "LOG SQL \uD568\uC218\uB294 \uC9C0\uC815\uB41C \uBC11\uC5D0\uC11C \uC22B\uC790\uC758 \uC790\uC5F0\uB85C\uADF8\uB97C \uAD6C\uD569\uB2C8\uB2E4."
language: ko
source_language: en
translation_state: complete
canonical: https://documentation.invantive.eu/ko/docs/invantive-universalsql/grammar/sql-functions/log
original: https://documentation.invantive.eu/en/docs/invantive-universalsql/grammar/sql-functions/log
updated: 2026-12-04T13:55:53Z
license: https://documentation.invantive.eu/ko/
---

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

## 목적
`LOG` SQL 함수는 지정된 밑에서 숫자의 자연로그를 구합니다.

[[LN]] 및 [[EXP]]도 참조하십시오.

매개변수:
- 입력 (`decimal`): 로그를 구할 숫자입니다.
- 밑 (선택 사항, `decimal`): 로그의 밑이 되는 값입니다. 기본값은 자연상수 e입니다.

반환값: 지정된 밑에서 입력값의 자연로그입니다.

## 예시
다음 예제는 밑 2에서 8의 로그를 조회합니다:
```sql
select log(8, 2)

-------------------
3
```
다음 예제는 밑 10에서 100의 로그를 조회합니다:
```sql
select log(100, 10)

-------------------
2
```
다음 예제는 1의 자연로그를 구합니다:
```sql
select log(1)

-------------------
0
```

