

 Amazon Redshift は、パッチ 198 以降、新しい Python UDF の作成をサポートしなくなります。既存の Python UDF は、2026 年 6 月 30 日まで引き続き機能します。詳細については、[ブログ記事](https://aws.amazon.com/blogs/big-data/amazon-redshift-python-user-defined-functions-will-reach-end-of-support-after-june-30-2026/)を参照してください。

# STL\$1USERLOG
<a name="r_STL_USERLOG"></a>

データベースユーザーに対する次の変更の詳細を記録します。
+ ユーザーの作成
+ ユーザーの削除
+ ユーザーの変更 (名前の変更)
+ ユーザーの変更 (プロパティの変更)

STL\$1USERLOG はスーパーユーザーのみに表示されます。詳細については、「[システムテーブルとビューのデータの可視性](cm_chap_system-tables.md#c_visibility-of-data)」を参照してください。

このテーブルの一部またはすべてのデータは、SYS モニタリングビュー [SYS\$1USERLOG](SYS_USERLOG.md) でも確認できます。SYS モニタリングビューのデータは、使いやすく理解しやすいようにフォーマットされます。クエリには、SYS モニタリングビューを使用することをお勧めします。

## テーブルの列
<a name="r_STL_USERLOG-table-columns"></a>

[\[See the AWS documentation website for more details\]](http://docs.aws.amazon.com/ja_jp/redshift/latest/dg/r_STL_USERLOG.html)

## サンプルクエリ
<a name="r_STL_USERLOG-sample-queries"></a>

次の例は、4 つのユーザーアクションを実行してから、STL\$1USERLOG ビューをクエリします。

```
create user userlog1 password 'Userlog1';
alter user userlog1 createdb createuser;
alter user userlog1 rename  to userlog2;
drop user userlog2;

select userid, username, oldusername, action, usecreatedb, usesuper from stl_userlog order by recordtime desc;
```

```
 userid |  username | oldusername |  action | usecreatedb | usesuper
--------+-----------+-------------+---------+-------------+----------
    108 | userlog2  |             | drop    |           1 |   1
    108 | userlog2  | userlog1    | rename  |           1 |   1
    108 | userlog1  |             | alter   |           1 |   1
    108 | userlog1  |             | create  |           0 |   0
 (4 rows)
```