diff --git a/tools/goctl/goctl.go b/tools/goctl/goctl.go index 4439e895..8355d2a8 100644 --- a/tools/goctl/goctl.go +++ b/tools/goctl/goctl.go @@ -456,7 +456,7 @@ var ( Flags: []cli.Flag{ cli.StringFlag{ Name: "url", - Usage: `the data source of database,like "root:password@tcp(127.0.0.1:3306)/database`, + Usage: `the data source of database,like "root:password@tcp(127.0.0.1:3306)/database"`, }, cli.StringFlag{ Name: "table, t", @@ -497,7 +497,7 @@ var ( Flags: []cli.Flag{ cli.StringFlag{ Name: "url", - Usage: `the data source of database,like "root:password@tcp(127.0.0.1:3306)/database`, + Usage: `the data source of database,like "postgres://root:password@127.0.0.1:54332/database?sslmode=disable"`, }, cli.StringFlag{ Name: "table, t", diff --git a/tools/goctl/model/sql/command/command.go b/tools/goctl/model/sql/command/command.go index e56e0322..fa016c5e 100644 --- a/tools/goctl/model/sql/command/command.go +++ b/tools/goctl/model/sql/command/command.go @@ -199,7 +199,7 @@ func fromMysqlDataSource(url, pattern, dir string, cfg *config.Config, cache, id func fromPostgreSqlDataSource(url, pattern, dir, schema string, cfg *config.Config, cache, idea bool) error { log := console.NewConsole(idea) if len(url) == 0 { - log.Error("%v", "expected data source of mysql, but nothing found") + log.Error("%v", "expected data source of postgresql, but nothing found") return nil }