partiql-js
v0.202107.0
Published
<div align="center"> <h1><code>partiql-js</code></h1> <strong>An implementation of PartiQL written in Rust</strong>
Downloads
6
Readme
Installation
npm add partiql
yarn add partiql
Usage
import partiql
def test_evaluate():
sql = "SELECT NAME, LOGNAME"
input = """
{
"SHELL": "/bin/bash",
"NAME": "my machine name",
"PWD": "/home/fuyutarow/partiql-rs",
"LOGNAME": "fuyutarow",
"HOME": "/home/fuyutarow",
"LANG": "C.UTF-8",
"USER": "fuyutarow",
"HOSTTYPE": "x86_64",
"_": "/usr/bin/env"
}
"""
expected = """[{"NAME":"my machine name","LOGNAME":"fuyutarow"}]"""
assert (
partiql.evaluate(
sql,
input,
"json",
"json",
)
== expected
)
Familiy
| content | lang | package | | --- | --- | --- | | pq | CLI (brew, scoop) | | | partiql-rs | Rust (cargo) | https://crates.io/crates/partiql-rs | | partiql-js | JavaScript (npm) | https://www.npmjs.com/package/partiql-js | | partiql-py | Python (pip) | https://pypi.org/project/partiql |