mongodb报错:E QUERY [thread1] SyntaxError: missing ; before statement @(shell):1:4
晚上在安装mongodb,设置密码后,如果直接连接mongodb,不用密码,虽然可以连上,但是会无法切换到指定数据库:
-> # mongo
MongoDB shell version v3.6.3
connecting to: mongodb://127.0.0.1:27017
MongoDB server version: 3.6.3
> 1+1
2
> use admin
2019-03-27T22:42:21.838+0800 E QUERY [thread1] SyntaxError: missing ; before statement @(shell):1:4
解决方法是连接时加上密码:
-> # mongo --port 27017 -u "myUserAdmin" -p "abc123" --authenticationDatabase "admin"
MongoDB shell version v3.6.3
connecting to: mongodb://127.0.0.1:27017/
MongoDB server version: 3.6.3
> use test
switched to db test
mongodb报错:E QUERY [thread1] SyntaxError: missing ; before statement @(shell):1:4相关推荐
- servlet-新建maven报错:web.xml is missing and <failOnMissingWebXml> is set to true
web项目: 新建maven报错:web.xml is missing and is set to true 解决: 勾选项目右键点击-->Java EE Tools-->Generate ...
- mongodb报错:Problem inserting to mongo collection: no reachable servers
文章目录 mongodb报错:Problem inserting to mongo collection: no reachable servers mongodb报错:Problem inserti ...
- jpa Specification fetch查询报错,query specified join fetching, but the owner of the fetched association
jpa Specification fetch查询报错,query specified join fetching, but the owner of the fetched association ...
- 【Eclipse 报错】Project ‘xxx‘ is missing required library
Eclispe报错: Project 'xxx' is missing required library: 'D:\Workspaces\javatest\lib\hamcrest-core-1.3. ...
- Python Docker 镜像使用yum命令报错 except KeyboardInterrupt, e: SyntaxError: invalid syntax
Python 环境 Centos Docker 镜像使用yum命令报错 except KeyboardInterrupt, e: SyntaxError: invalid syntax 在Python ...
- 解决MongoDB报错:Cannot create collection “None“ as a capped collection as it already exist
解决MongoDB报错:Cannot create collection "None" as a capped collection as it already exist Roo ...
- WSL2使用Python访问Windows 10上的MongoDB报错:pymongo.errors.ServerSelectionTimeoutError: localhost:27017: [Er
WSL2使用Python访问Windows 10上的MongoDB报错:pymongo.errors.ServerSelectionTimeoutError: localhost:27017: [Er ...
- php数据库报错1046怎么解决,DZ报错MySQL Query Error Errno:1046错误的解决办法
这篇文章主要为大家详细介绍了DZ报错MySQL Query Error Errno:1046错误的解决办法,具有一定的参考价值,感兴趣的小伙伴们可以参考一下,有需要的朋友可以收藏方便以后借鉴. DZ报 ...
- Keil 报错 declaration may not appear after executable statement in block的解决办法
Keil 报错 declaration may not appear after executable statement in block的解决办法 在移植修改例程代码时,Keil 报错 " ...
最新文章
- linux c 自定义信号 测试kill信号发送
- 感觉灵感被掏空?你需要这 9 篇论文来补一补 | PaperDaily #05
- 家装强电弱电布线图_家装电路改造注意事项是什么?深圳广田家透彻分析全搞定...
- IAP上线后查不到product id
- figsize, dpi参数
- java pdf版本转换_无需依赖第三方软件,在Java中进行PDF格式转换全新攻略
- python词性标注_Python NLTK学习5(词性标注)
- Simultaneous accesses to 0x1c5a674c8, but modification requires exclusive access.
- linux 开机运行命令
- 数学公式——海伦公式
- 中级育婴师证怎么考,需要些什么条件
- NR SSB Beam Sweeping
- 网上看到的Android面试题集合(精)
- mongodb 地理距离_MongoDB地理空间移动演示
- matlab自动驾驶工具箱,MATLAB,Simulink. - Automated Driving System Toolbox, 自動駕駛系統工具箱-鈦思科技...
- vijos1404 遭遇战
- Linux基础——之一命令
- ppt怎么压缩文件大小?试试这几种方法
- HCNP-RS 笔试结果
- RGB565转RGB888原理 (MATLAB代码)
热门文章
- PubChem的Python接口PubChemPy
- 在线作图丨高级的微生物分析——在线做Variance Partitioning Analysis(VPA分析)
- NAR:浙大陈云/马忠华团队揭示病原真菌组蛋白H3K27甲基化识别新机制
- ​GEB:焦硕等发表生态位的系统发育保守性决定土壤古菌地理格局
- 植物微生物组专题:研究方法、当前热点及未来方向
- 关于肠道菌群研究的7大事实和5大倡议
- 口腔菌群让你心口一致——牙疼和心脏病都会犯
- R语言plotly可视化:plotly可视化在散点图中添加误差条(Scatterplot with Error Bars with plotly in R)
- R语言ggplot2可视化添加希腊字母标签:图表题(title)中加入希腊字母、图中加入希腊字母标签
- R语言dplyr包near函数查看向量对应元素是否相同或者相近实战