Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mongodb development #3

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,45 @@

<br><br>


# MongoDB collection created by joining of mysql tables listed above.

## Description

*MongoDB supports query operations on geospatial data. You could get more information from https://docs.mongodb.com/manual/geospatial-queries*


## Installation

*Follow the steps below to import the collection.*

**Linux/OSX command line:**

$ gunzip world.json.gz
$ mongoimport --db mydatabase --collection mycollection --file world.json


**Windows**

- Install 7zip (so you can extract gzip files)
- Extract world.json.gz and then use the same mongoimport command lines as Linux above on the `world.json` file

## Data Structure of collection


| Field | Type | Description |
| ------------- |:---------------------------------------------| :---------------------------------------------|
| _id | ObjectId | Unique key of collection |
| name | String | City name |
| region | String | Region name |
| country | String | Country name |
| location | GeoJSON Point | Location data |

*You could find more information about GeoJsonPoint on the https://docs.mongodb.com/manual/reference/geojson/#point*

<br><br>


## License for MaxMind WorldCities Database

OPEN DATA LICENSE for MaxMind WorldCities and Postal Code Databases
Expand Down
Binary file added mongodb/world.json.gz
Binary file not shown.
File renamed without changes.