Features:
- Common sqlpp types support
- Auto increment columns support
- Nullable fields support
Requirements:
- NodeJS 18+;
- Linux/Windows/Mac;
- Yarn or NPM.
- Clone repository
git clone https://github.com/mayerdev/sqlpp-model-generator
- Create
config.json
and fill them:
{
"host": "<HOST or IP>",
"user": "<USER>",
"password": "<PASSWORD>",
"database": "<DATABASE NAME>"
}
- Install packages
npm install
or
yarn
- Generate model from table.
Method 1:
node generator.js <table> > out.hpp
Method 2:
node generator.js <table> out.hpp