Holana/Database Examples
2023-03-19 23:00:51 +13:00
..
index4mongo.js Reverted more files 2023-03-19 23:00:51 +13:00
index4mysql.js Reverted more files 2023-03-19 23:00:51 +13:00
README.md Reverted more files 2023-03-19 23:00:51 +13:00

Custom/External Database

you can use the pre-built available database example in your bot as your need. Read the following carefully to understand the Custom Databases.

Database Setup

SQL Database Setup
- Copy the code from the given file from: ./Database Examples/index4mysql.js.
- Install the mysql package: `npm i mysql`.
- Insert your DB values.
and that's it start the bot and it should work.
MongoDB Setup
- Copy the code from the given file from: ./Database Examples/index4mongo.js.
- Install the quickmongo package: npm i quickmongo
- Add your connection string in the config file with the following variable: "mongo_url": "your-mongo-connection-string"
and that's it start the bot and it should work.