怎么在java中实现类似show dbs 这样的mongo语句啊?是用db.eval这个方法吗?具体怎么用啊,求指教啊
关注
码龄 粉丝数 原力等级 --
- 被采纳
- 被点赞
- 采纳率
怎么在java中实现类似show dbs 这样的mongo语句啊?
收起
- 写回答
- 好问题 0 提建议
- 追加酬金
- 关注问题
- 微信扫一扫点击复制链接分享
- 邀请回答
- 编辑 收藏 删除 结题
- 收藏 举报
追加酬金 (90%的用户在追加酬金后获得了解决方案)
当前问题酬金
¥ 0 (可追加 ¥500)
支付方式
扫码支付
加载中...
0条回答 默认 最新
报告相同问题?
提交
- 2019-08-27 13:08回答 1 已采纳 Simply filter by the name property, which denotes the database name. And to list databases startin
- 2023-03-20 21:14回答 2 已采纳 B不太合适吧,转储是用于数据恢复的措施吧
- 2019-05-07 09:52回答 1 已采纳 The comment from the user mickmackusa solves the problem. His solution works perfectly! if ($chil
- 2021-03-03 23:48weixin_39845039的博客 开启mongo服务/usr/local/opt/mongodb/bin/mogod链接mongomongo查看所有的库show dbs选择库use 库名查看所有的表db.getCollectionNames();查看表的所有数据db.表明.find()创建MongoDB 创建数据库的语法格式如下use ...
- 2017-10-07 21:04回答 1 已采纳 This took me longer to find than I would have hoped. There is one obvious problem, you are not ba
- 2014-04-09 13:35回答 1 已采纳 What you're looking for is an AbstractFactory, which itself is capable of determining from a servi
- 2011-07-11 08:12回答 2 已采纳 you are mixing CI and php native mssql driver. $this->suburbDb is CI database object not link
- 2021-12-28 11:57rs勿忘初心的博客 print(doc['_id']) # 去重后的字段值 3、权限操作 3.1 创建只读用户 use mytest // 创建数据库 db.createCollection('book') // 创建集合,以方便 show dbs 能显示数据库 db.createUser({ user: 'myread', pwd: 'my...
- 2014-12-22 05:41回答 1 已采纳 The problem is with your smarty code in the second foreach loop Replace This line of your code
- 2012-04-12 05:42回答 3 已采纳 Querying all three tables at the same time for this purpose will be not a good practice. You can c
- 2017-10-12 18:06回答 3 已采纳 I figured it out. You do in fact have to have php70-pdo-dblib installed and restart the server. Ho
- 2021-04-22 05:31alias e的博客 //库:show dbs //显示所有库db //当前库use 库名 //自动创建新库db.dropDatabase() //删除库show tables(collections) //显示当前数据库的(表/集合)//表/集合:db.createCollection("表名",{ capped : true, ...
- 2014-10-01 03:55回答 1 已采纳 From the documentation for invoke: Note: If the function has arguments that need to be referen
- 2021-03-15 18:20er0s10n的博客 在项目中MongoDB的Map-Reduce功能做了许多统计任务,在重构代码的时候修改了_id对象里面的属性字段名称,当用db.collection.update({$rename:{"_id.a":"_id.b"}})的时候提示mongodb $rename affecting _id not ...
- 2021-05-12 08:07颜语一声的博客 我想在shell脚本中执行mongo命令,例如 在脚本test.sh中:#!/bin/shmongo myDbNamedb.mycollection.findOne()show collections当我通过./test.sh执行此脚本时,将建立与MongoDB的连接,但不执行以下命令。如何通过...
- 2019-06-28 10:25彡克莱因瓶的博客 输入:show dbs/tables(collections) 3.连接指定数据库,如果没有该数据库,则自动新建: 输入:use dbname 4.显示当前所在数据库: 输入:db 5.删除当前所在数据库:(可用db来确认所在数据库名) ...
- 2021-02-03 11:26您创建的数据库(ugurdb),但不在列表中。 (因为尚无数据) >db ugurdb >show dbs local 0.000GB config 0.000GB admin 0.000GB 创建收藏集(表) 当您插入一些文档时,MongoDB会自动创建集合。 您也可以在之前...
- 2016-09-07 14:14weixin_33835103的博客 一、基础语句1.创建数据库并查看当前数据库 > use wang > db2.查看数据库的版本 > db.version()3.删除数据库 > use wang > db.dropDatabase()4.插入文档 > db.test.insert({ id : 1 , "name " : ...
- 2019-07-29 11:24黑白神的博客 Mongo数据库执行语句 SQL术语/概念 MongoDB术语/概念 解释/说明 database database 数据库 table collection 数据库表/集合 row document 数据记录行/文档 column field 数据字段/域 index index ...
- 2022-06-06 16:29wr456wr的博客 使用Java操作mongoDB,对mongoDB进行增删改查等操作
- 没有解决我的问题, 去提问