Socket
Book a DemoInstallSign in
Socket

buildmsql

Package Overview
Dependencies
Maintainers
1
Versions
57
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

buildmsql

buildmsql build sql for mariadb connector

Source
npmnpm
Version
1.6.9
Version published
Weekly downloads
11
450%
Maintainers
1
Weekly downloads
 
Created
Source

buildmsql

buildmsql is a builder sql for mariadb connector

Description

buildmsql helps you build sql for mariadb connector

Documentation - https://webigorkiev.github.io/buildmsql/

Installation

npm i buildmsql

Usage

Single connection


import {Query, QueryOptions} from "buildmsql";

const db = new Query(opt as {
    // QueryOpinions
    // Debug level: 0 - no debag info, 1 - _buildmsqlQueries text and timing
    debug?: 0|1,

    // Used for manticore search
    nativeTransactions?: boolean,

    // pattern *string* regex pattern to select pools. Example, `"slave*"`. default `'*'`
    pattern?:string,

    // *string* pools selector. Can be 'RR' (round-robin),
    // 'RANDOM' or 'ORDER' (use in sequence = always use first pools unless fails)
    selector?: "RR"|"RANDOM"|"ORDER"
})

const connection = await db.createConnection({
    host: 'mydb.com',
    user:'myUser',
    password: 'myPwd'
    
    // mariadb.ConnectionConfig
});

Pool

import {Query, QueryOptions} from "buildmsql";

const db = new Query({
    // QueryOpinions
})

const pool = db.createPool({
    // mariadb.PoolConfig
})

Keywords

maraidb

FAQs

Package last updated on 22 Feb 2023

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts