From a9fe67ce242b963a37a6d6ac1862d65fc1aa2791 Mon Sep 17 00:00:00 2001 From: liyang Date: Tue, 24 Sep 2024 01:48:41 +0800 Subject: [PATCH] chore: change table name --- examples/README.md | 2 +- examples/{hint => hints}/README.md | 8 ++++---- examples/{hint => hints}/main.go | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) rename examples/{hint => hints}/README.md (93%) rename examples/{hint => hints}/main.go (98%) diff --git a/examples/README.md b/examples/README.md index 6634847..b8438be 100644 --- a/examples/README.md +++ b/examples/README.md @@ -16,7 +16,7 @@ docker run --rm -p 4000-4003:4000-4003 \ - [table](table/README.md) - [object](object/README.md) - [healthcheck](healthcheck/README.md) -- [hint](hint/README.md) +- [hints](hints/README.md) ## Query diff --git a/examples/hint/README.md b/examples/hints/README.md similarity index 93% rename from examples/hint/README.md rename to examples/hints/README.md index 46a2b46..42d3698 100644 --- a/examples/hint/README.md +++ b/examples/hints/README.md @@ -9,7 +9,7 @@ go run main.go Output: ```log -2024/09/24 01:16:03 create table, name: 'monitor_table_with_hint' +2024/09/24 01:16:03 create table, name: 'monitor_table_with_hints' 2024/09/24 01:16:03 affected rows: 3 ``` @@ -20,7 +20,7 @@ Your can using [MySQL Client](https://docs.greptime.com/user-guide/protocols/mys ```shell $ mysql -h 127.0.0.1 -P 4002 public -mysql> select * from monitor_table_with_hint; +mysql> select * from monitor_table_with_hints; +------+-------+-------------+----------------------------+ | id | host | temperature | timestamp | +------+-------+-------------+----------------------------+ @@ -34,11 +34,11 @@ mysql> select * from monitor_table_with_hint; You can view hints using `show create table` command: ```mysql -mysql> show create table monitor_table_with_hint; +mysql> show create table monitor_table_with_hints; +------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | Table | Create Table | +------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| monitor_table_with_hint | CREATE TABLE IF NOT EXISTS `monitor_table_with_hint` ( +| monitor_table_with_hints | CREATE TABLE IF NOT EXISTS `monitor_table_with_hints` ( `id` BIGINT NULL, `host` STRING NULL, `temperature` DOUBLE NULL, diff --git a/examples/hint/main.go b/examples/hints/main.go similarity index 98% rename from examples/hint/main.go rename to examples/hints/main.go index 19247bd..13a2122 100644 --- a/examples/hint/main.go +++ b/examples/hints/main.go @@ -49,7 +49,7 @@ func initData() []*table.Table { time2 := time.Now() time3 := time.Now() - itbl, err := table.New("monitor_table_with_hint") + itbl, err := table.New("monitor_table_with_hints") if err != nil { log.Println(err) return nil