2023-02-09から1日間の記事一覧

インデックススキャンでnot nullカラムをcountする場合のテーブルルックアップ有無

DB

MySQL (8.0.31)https://dev.mysql.com/doc/refman/8.0/en/explain-output.html#jointype_index drop table tab1;create table tab1(col1 int primary key ,col2 int ,col3 int not null ); create index ind1 on tab1(col1,col2); explainselect /*+ INDEX(t…

ユーザ名最大長

DB

MySQL 32文字Oracle 128文字PostgreSQL 63文字SQL Server 128文字 MySQL (8.0.31) https://dev.mysql.com/doc/refman/8.0/ja/user-names.html MySQL ユーザー名の長さは最大 32 文字です。 オペレーティングシステムのユーザー名の最大長が異なる場合があり…