Optimize index structure of counter_log table for quick querying when a new visitor arrives

This commit is contained in:
Kijin Sung 2025-09-04 01:14:43 +09:00
parent 9b18c48256
commit 4a84f52edb
2 changed files with 33 additions and 3 deletions

View file

@ -1,6 +1,8 @@
<table name="counter_log">
<column name="site_srl" type="bigint" notnull="notnull" default="0" index="idx_site_counter_log" />
<column name="ipaddress" type="varchar" size="60" notnull="notnull" index="idx_site_counter_log" />
<column name="regdate" type="date" notnull="notnull" index="idx_counter_log" />
<column name="id" type="bigint" notnull="notnull" primary_key="primary_key" auto_increment="auto_increment" />
<column name="site_srl" type="bigint" notnull="notnull" default="0" />
<column name="regdate" type="date" notnull="notnull" />
<column name="ipaddress" type="varchar" size="60" notnull="notnull" />
<column name="user_agent" type="varchar" size="250" />
<index name="idx_regdate_ipaddress" columns="regdate(8),ipaddress" />
</table>