1.24.0 • Published 4 years ago

ordek-db v1.24.0

Weekly downloads
-
License
MIT
Repository
-
Last release
4 years ago

Image Image Image

Image

ordek-db

Readable database for js.

İnstall

npm i ordek-db

Yarn Users

yarn add ordek-db

Update news version 1.24.0

Codes Optimized,

A function to save data as array has been added.

☑️ Usage

TypeScript

import Database from"ordek-db"
const db = new Database("databasefile")

JavaScript

//usage
const Database = require("ordek-db")//=> defining module
const db = new Database("databasefile")//=> defining database, If you do not enter the database file, the module itself sets the create file



db.write('test', '?')//=> set/write data to the database.
db.writeArray("test", "2")//=> Records Data in Array Form
db.add('example', 2)//=> collecting numerical values from the database.
db.substr('db', 7)//=> subtracting numerical values from the database.
db.multiplication('db2', 7)//=> multiplication numerical values from the database.
db.dividing('db6', 2)//=> dividing numerical values from the database.
db.math('example4', '+', 4, false)//=> Math Operator, options(+, -, *, /, %)
db.fetch('database')//=> fetching/geting database data.
db.all()//=> Fetch all data
db.fetchAll()//=> Fetch all data
db.push("array1", 10);//=> pushing data
db.control('prefix')//=> control/has of data in the database.
db.backup('data.json')//=> backing up data on the database in a different file.
db.delete('data')//=> delete data.
db.clear()//=> no values are written in parentheses and resets the database
db.destroy()//=> no values are written, destroy database.
db.version()//=> no value is entered and shows the version of the module
db.type("test1"); //=> Get data type, note: value must be number
db.startsWith("dt")//=> DB Find a startsWith

💯 Math Functions

const Database = require("ordek-db")//=> defining module.
const db = new Database("databasefile")//=> defining database, If you do not enter the database file, the module itself sets the   database file.



//functions
db.add('test4', 3)//=> collecting numerical values from the database.
db.substr('test5', 2)//=> subtracting numerical values from the database.
db.multiplication('db2', 7)//=> multiplication numerical values from the database.
db.dividing('db6', 2)//=> dividing numerical values from the database.
db.math('example4', '+', 4, false)//=> Math Operator options(+, -, *, /, %).

Delete Functions

const Database = require("ordek-db")//=> defining module.
const db = new Database("Database File")//=> defining database, If you do not enter the database file, the module itself sets the   database file.

db.delete('data')//=> delete data.
db.clear()//=> no values are written in parentheses and resets the database.
db.destroy()//=> destroy database.
1.24.0

4 years ago

1.22.0

4 years ago

1.21.0

4 years ago

1.20.0

4 years ago

1.19.0

4 years ago

1.18.0

4 years ago

1.17.0

4 years ago

1.16.0

4 years ago

1.15.0

4 years ago

1.14.0

4 years ago

1.13.0

4 years ago

1.12.0

4 years ago

1.11.0

4 years ago

1.10.0

4 years ago

1.9.0

4 years ago

1.8.0

4 years ago

1.7.0

4 years ago

1.6.0

4 years ago

1.5.0

4 years ago

1.4.0

4 years ago

1.3.0

4 years ago