官术网_书友最值得收藏!

Creating a database

Let's start by defining the database that we are going to work with. In your shell, execute the following:

> use OrderBase

This will ask MongoDB to switch to a new database, called OrderBase, that we wish to run the commands against. The response will be as follows:

switched to db OrderBase

But wait, how can we switch to a database that does not exist yet? MongoDB flexibility to the rescue! When you tell MongoDB to use a database, it will create that database for you automatically before switching to it.

主站蜘蛛池模板: 资溪县| 江山市| 璧山县| 平武县| 建始县| 甘南县| 湾仔区| 遂溪县| 萨嘎县| 涟水县| 富蕴县| 长汀县| 伽师县| 扬中市| 高台县| 胶南市| 河东区| 浦县| 清丰县| 资阳市| 刚察县| 麻阳| 平乡县| 兴和县| 江津市| 大英县| 即墨市| 商河县| 山东省| 凌源市| 综艺| 庆元县| 北安市| 孝义市| 都安| 麻江县| 丰顺县| 永安市| 桃江县| 靖宇县| 岐山县|