1.17.0 • Published 3 years ago

@wmfs/pg-concat v1.17.0

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

pg-concat

Tymly Package npm (scoped) CircleCI codecov CodeFactor Dependabot badge Commitizen friendly JavaScript Style Guide license FOSSA Status

Takes an array of parts and returns the necessary PostgreSQL expression to concatenate them.

Usage

const pgConcat = require('pg-concat')

const concatString = pgConcat(
    [
        { columnName: 'incident_no' },
        '/',
        { columnName: 'year', default: 1900 },
    ]
)

// concatString = 'incident_no||'/'||COALESCE(year, 1900)'

Install

$ npm install pg-concat --save

License

MIT

FOSSA Status

1.17.0

3 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

5 years ago

1.9.0

5 years ago

1.8.0

5 years ago

1.7.0

6 years ago

1.6.0

6 years ago

1.5.0

6 years ago

1.4.0

6 years ago

1.3.0

6 years ago

1.2.0

6 years ago

1.1.0

6 years ago

1.0.0

6 years ago