Skip to content

rgunindi/go-mongo-schema-creator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go MongoDB Schema Creator

This project is a tool for generating MongoDB schemas from JSON data. It reads a JSON file and creates a BSON document that represents the data in the JSON file. The BSON document can be used to create a MongoDB collection with the correct structure for the data.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

You will need the following software installed on your machine:

Installing

To install the project, follow these steps:

  1. Clone the repository: git clone https://github.com/Ramazan-xcod3r/goMongoSchemaCreator.git
  2. Change into the project directory: cd goMongoSchemaCreator
  3. Run the project: go run main.go --test data.json

The --test flag is optional and can be used to test the data insertion into the database. The data.json file is the JSON file that the tool will read and create the BSON document from.

Usage

To use the tool, run the following command:

go run main.go [--test] [data.json]

The --test flag is optional and can be used to test the data insertion into the database. The data.json file is the JSON file that the tool will read and create the BSON document from.

Example

image

Authors

License

This project is licensed under the MIT License

About

This project created for schema from json data

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages