go-city演示Go-city sync --dbname=WEBcron --driver=database --table=city 100% |██████████████████
Go-city sync --dbname=WEBcron --driver=database --table=city
100% |█████████████████████████████████████████| (34/34, 2 it/min)
time="2023-03-04T10:29:26+08:00" level=info msg="数据同步完成,其中省级行政区:34,城市:452,区县:5234,乡镇街道:43564"
go install https://GitHub.com/xiaoxuan6/go-city.git
go-city sync --db=./sqlite.db
go-city sync --driver=database --host=127.0.0.1 --port=3306 --username=root --passWord=root --dbname=city --table=city
NAME:
go-city sync
USAGE:
go-city sync [command options] [arguments...]
DESCRIPTION:
同步省市区到数据库
OPTIONS:
--driver value, -d value db driver,Support:sqlite、database、memory (default: "sqlite") [%GO_CITY_DRIVER%]
--db value database file (default: "./sqlite.db") [%GO_CITY_DB%]
--host value database host (default: "127.0.0.1") [%GO_CITY_DB_HOST%]
--port value database port (default: "3306") [%GO_CITY_DB_PORT%]
--username value database username (default: "root") [%GO_CITY_DB_USERNAME%]
--password value database password (default: "root") [%GO_CITY_DB_PASSWORD%]
--dbname value database dbname [%GO_CITY_DB_NAME%]
--table value database table name (default: "cities") [%GO_CITY_DB_TABLE_NAME%]
--help, -h show help
不要轻易放弃。学习成长的路上,我们长路漫漫,只因学无止境 Don't give up easily. On the way of learning and growing up, we have a long way to go, just because there is no end to learning.
--结束END--
本文标题: 爬取全国「省市区县乡镇街道」数据来源于[京东]
本文链接: https://lsjlt.com/news/198752.html(转载时请注明来源链接)
有问题或投稿请发送至: 邮箱/279061341@qq.com QQ/279061341
2024-04-05
2024-04-05
2024-04-05
2024-04-04
2024-04-05
2024-04-05
2024-04-05
2024-04-05
2024-04-04
回答
回答
回答
回答
回答
回答
回答
回答
回答
回答
0